@shortstravelmgmt/component-lib 0.1.13 → 0.1.15
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/index.d.ts +46 -2
- package/dist/index.esm.js +417 -383
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +419 -382
- package/dist/index.js.map +1 -1
- package/dist/styles.css +1 -1
- package/dist/styles.css.map +1 -1
- package/package.json +1 -1
package/dist/index.esm.js
CHANGED
|
@@ -108,7 +108,7 @@ const Icons = {
|
|
|
108
108
|
Trash: TrashIcon$2,
|
|
109
109
|
};
|
|
110
110
|
|
|
111
|
-
var styles$
|
|
111
|
+
var styles$1f = {"alert":"Alert-module_alert__xxiES","content":"Alert-module_content__CVX32","icon":"Alert-module_icon__Xyh6J","body":"Alert-module_body__TTkmt","title":"Alert-module_title__7wNPO","message":"Alert-module_message__plreL","dismissButton":"Alert-module_dismissButton__MdRWh","primary":"Alert-module_primary__nME13","success":"Alert-module_success__GDt4S","warning":"Alert-module_warning__y4bLx","error":"Alert-module_error__nKMAG"};
|
|
112
112
|
|
|
113
113
|
const variantIcons = {
|
|
114
114
|
primary: LightbulbIcon,
|
|
@@ -118,10 +118,10 @@ const variantIcons = {
|
|
|
118
118
|
};
|
|
119
119
|
const Alert = ({ variant = 'primary', title, children, dismissible = false, onDismiss, className = '', }) => {
|
|
120
120
|
const IconComponent = variantIcons[variant];
|
|
121
|
-
return (jsx("div", { className: `${styles$
|
|
121
|
+
return (jsx("div", { className: `${styles$1f.alert} ${styles$1f[variant]} ${className}`, role: "alert", children: jsxs("div", { className: styles$1f.content, children: [jsx(IconComponent, { className: styles$1f.icon, size: 20 }), jsxs("div", { className: styles$1f.body, children: [title && jsx("h4", { className: styles$1f.title, children: title }), jsx("div", { className: styles$1f.message, children: children })] }), dismissible && onDismiss && (jsx("button", { type: "button", onClick: onDismiss, className: styles$1f.dismissButton, "aria-label": "Dismiss alert", children: jsx(CloseIcon, { size: 16 }) }))] }) }));
|
|
122
122
|
};
|
|
123
123
|
|
|
124
|
-
var styles$
|
|
124
|
+
var styles$1e = {"avatar":"Avatar-module_avatar__AcTRg","xs":"Avatar-module_xs__4uGxI","sm":"Avatar-module_sm__NvzTi","md":"Avatar-module_md__PgY8p","lg":"Avatar-module_lg__lhkAZ","xl":"Avatar-module_xl__qTDTF","image":"Avatar-module_image__GX2c9","initials":"Avatar-module_initials__58FHH","group":"Avatar-module_group__XW0b1","overflow":"Avatar-module_overflow__ul4Cc"};
|
|
125
125
|
|
|
126
126
|
const getInitials = (name) => {
|
|
127
127
|
const parts = name.trim().split(/\s+/);
|
|
@@ -136,43 +136,43 @@ const getInitials = (name) => {
|
|
|
136
136
|
const Avatar = ({ src, alt, initials, name, size = 'md', className = '', ...props }) => {
|
|
137
137
|
const displayInitials = initials || (name ? getInitials(name) : '?');
|
|
138
138
|
const classNames = [
|
|
139
|
-
styles$
|
|
140
|
-
styles$
|
|
139
|
+
styles$1e.avatar,
|
|
140
|
+
styles$1e[size],
|
|
141
141
|
className,
|
|
142
142
|
]
|
|
143
143
|
.filter(Boolean)
|
|
144
144
|
.join(' ');
|
|
145
|
-
return (jsx("div", { className: classNames, ...props, children: src ? (jsx("img", { src: src, alt: alt || name || 'Avatar', className: styles$
|
|
145
|
+
return (jsx("div", { className: classNames, ...props, children: src ? (jsx("img", { src: src, alt: alt || name || 'Avatar', className: styles$1e.image })) : (jsx("span", { className: styles$1e.initials, children: displayInitials })) }));
|
|
146
146
|
};
|
|
147
147
|
Avatar.displayName = 'Avatar';
|
|
148
148
|
const AvatarGroup = ({ max = 4, className = '', children, ...props }) => {
|
|
149
149
|
const childArray = React.Children.toArray(children);
|
|
150
150
|
const visibleChildren = childArray.slice(0, max);
|
|
151
151
|
const remainingCount = childArray.length - max;
|
|
152
|
-
const classNames = [styles$
|
|
153
|
-
return (jsxs("div", { className: classNames, ...props, children: [visibleChildren, remainingCount > 0 && (jsx("div", { className: `${styles$
|
|
152
|
+
const classNames = [styles$1e.group, className].filter(Boolean).join(' ');
|
|
153
|
+
return (jsxs("div", { className: classNames, ...props, children: [visibleChildren, remainingCount > 0 && (jsx("div", { className: `${styles$1e.avatar} ${styles$1e.md} ${styles$1e.overflow}`, children: jsxs("span", { className: styles$1e.initials, children: ["+", remainingCount] }) }))] }));
|
|
154
154
|
};
|
|
155
155
|
AvatarGroup.displayName = 'AvatarGroup';
|
|
156
156
|
|
|
157
|
-
var styles$
|
|
157
|
+
var styles$1d = {"badge":"Badge-module_badge__lvuUg","sm":"Badge-module_sm__OTBAp","md":"Badge-module_md__YG44i","dot":"Badge-module_dot__RgcVD","default":"Badge-module_default__1ga4w","success":"Badge-module_success__jEfI9","warning":"Badge-module_warning__978mf","error":"Badge-module_error__xZJlm","info":"Badge-module_info__Xk7MM"};
|
|
158
158
|
|
|
159
159
|
/**
|
|
160
160
|
* Badge component for status indicators, labels, and tags.
|
|
161
161
|
*/
|
|
162
162
|
const Badge = ({ variant = 'default', size = 'md', dot = false, className = '', children, ...props }) => {
|
|
163
163
|
const classNames = [
|
|
164
|
-
styles$
|
|
165
|
-
styles$
|
|
166
|
-
styles$
|
|
164
|
+
styles$1d.badge,
|
|
165
|
+
styles$1d[variant],
|
|
166
|
+
styles$1d[size],
|
|
167
167
|
className,
|
|
168
168
|
]
|
|
169
169
|
.filter(Boolean)
|
|
170
170
|
.join(' ');
|
|
171
|
-
return (jsxs("span", { className: classNames, ...props, children: [dot && jsx("span", { className: styles$
|
|
171
|
+
return (jsxs("span", { className: classNames, ...props, children: [dot && jsx("span", { className: styles$1d.dot }), children] }));
|
|
172
172
|
};
|
|
173
173
|
Badge.displayName = 'Badge';
|
|
174
174
|
|
|
175
|
-
var styles$
|
|
175
|
+
var styles$1c = {"button":"Button-module_button__xDdzH","sm":"Button-module_sm__fb2AF","md":"Button-module_md__XOa6t","lg":"Button-module_lg__UN9rL","square":"Button-module_square__-o34b","primary":"Button-module_primary__jWHqR","secondary":"Button-module_secondary__30FUq","outline":"Button-module_outline__v98mS","ghost":"Button-module_ghost__XUGB1","danger":"Button-module_danger__NUxPy","fullWidth":"Button-module_fullWidth__p2otK","loading":"Button-module_loading__TsL5I","spinner":"Button-module_spinner__6bZoj","spin":"Button-module_spin__ZPDMG","icon":"Button-module_icon__21hUM","content":"Button-module_content__iVRPQ"};
|
|
176
176
|
|
|
177
177
|
/**
|
|
178
178
|
* Primary button component for user interactions.
|
|
@@ -180,21 +180,21 @@ var styles$1a = {"button":"Button-module_button__xDdzH","sm":"Button-module_sm__
|
|
|
180
180
|
*/
|
|
181
181
|
const Button = forwardRef(({ variant = 'primary', size = 'md', fullWidth = false, loading = false, leftIcon, rightIcon, square = false, className = '', disabled, children, ...props }, ref) => {
|
|
182
182
|
const classNames = [
|
|
183
|
-
styles$
|
|
184
|
-
styles$
|
|
185
|
-
styles$
|
|
186
|
-
fullWidth ? styles$
|
|
187
|
-
square ? styles$
|
|
188
|
-
loading ? styles$
|
|
183
|
+
styles$1c.button,
|
|
184
|
+
styles$1c[variant],
|
|
185
|
+
styles$1c[size],
|
|
186
|
+
fullWidth ? styles$1c.fullWidth : '',
|
|
187
|
+
square ? styles$1c.square : '',
|
|
188
|
+
loading ? styles$1c.loading : '',
|
|
189
189
|
className,
|
|
190
190
|
]
|
|
191
191
|
.filter(Boolean)
|
|
192
192
|
.join(' ');
|
|
193
|
-
return (jsxs("button", { ref: ref, className: classNames, disabled: disabled || loading, ...props, children: [loading && (jsx("span", { className: styles$
|
|
193
|
+
return (jsxs("button", { ref: ref, className: classNames, disabled: disabled || loading, ...props, children: [loading && (jsx("span", { className: styles$1c.spinner, children: jsxs("svg", { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: [jsx("circle", { cx: "12", cy: "12", r: "10", strokeOpacity: "0.25" }), jsx("path", { d: "M12 2a10 10 0 0 1 10 10", strokeLinecap: "round" })] }) })), !loading && leftIcon && jsx("span", { className: styles$1c.icon, children: leftIcon }), children && jsx("span", { className: styles$1c.content, children: children }), !loading && rightIcon && jsx("span", { className: styles$1c.icon, children: rightIcon })] }));
|
|
194
194
|
});
|
|
195
195
|
Button.displayName = 'Button';
|
|
196
196
|
|
|
197
|
-
var styles$
|
|
197
|
+
var styles$1b = {"wrapper":"Checkbox-module_wrapper__tYM-f","label":"Checkbox-module_label__x7c9f","disabled":"Checkbox-module_disabled__YtL8b","checkboxWrapper":"Checkbox-module_checkboxWrapper__ez0mi","input":"Checkbox-module_input__xBHoX","checkbox":"Checkbox-module_checkbox__zGuTf","sm":"Checkbox-module_sm__naurE","md":"Checkbox-module_md__LlE6O","lg":"Checkbox-module_lg__dMWT-","hasError":"Checkbox-module_hasError__aCefd","labelText":"Checkbox-module_labelText__7arlw","helperText":"Checkbox-module_helperText__jR4oi","errorText":"Checkbox-module_errorText__u8puP"};
|
|
198
198
|
|
|
199
199
|
const CheckIcon$1 = () => (jsx("svg", { width: "10", height: "8", viewBox: "0 0 10 8", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: jsx("path", { d: "M1 4L3.5 6.5L9 1", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }) }));
|
|
200
200
|
const IndeterminateIcon = () => (jsx("svg", { width: "10", height: "2", viewBox: "0 0 10 2", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: jsx("path", { d: "M1 1H9", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round" }) }));
|
|
@@ -207,10 +207,10 @@ const Checkbox = forwardRef(({ label, size = 'md', helperText, error, indetermin
|
|
|
207
207
|
const helperId = `${checkboxId}-helper`;
|
|
208
208
|
const errorId = `${checkboxId}-error`;
|
|
209
209
|
const wrapperClasses = [
|
|
210
|
-
styles$
|
|
211
|
-
styles$
|
|
212
|
-
disabled ? styles$
|
|
213
|
-
error ? styles$
|
|
210
|
+
styles$1b.wrapper,
|
|
211
|
+
styles$1b[size],
|
|
212
|
+
disabled ? styles$1b.disabled : '',
|
|
213
|
+
error ? styles$1b.hasError : '',
|
|
214
214
|
className,
|
|
215
215
|
].filter(Boolean).join(' ');
|
|
216
216
|
// Handle indeterminate state via ref
|
|
@@ -226,13 +226,13 @@ const Checkbox = forwardRef(({ label, size = 'md', helperText, error, indetermin
|
|
|
226
226
|
ref.current = node;
|
|
227
227
|
}
|
|
228
228
|
};
|
|
229
|
-
return (jsxs("div", { className: wrapperClasses, children: [jsxs("label", { className: styles$
|
|
229
|
+
return (jsxs("div", { className: wrapperClasses, children: [jsxs("label", { className: styles$1b.label, children: [jsxs("div", { className: styles$1b.checkboxWrapper, children: [jsx("input", { ref: inputRef, type: "checkbox", id: checkboxId, className: styles$1b.input, disabled: disabled, checked: checked, "aria-invalid": !!error, "aria-describedby": [error ? errorId : null, helperText ? helperId : null]
|
|
230
230
|
.filter(Boolean)
|
|
231
|
-
.join(' ') || undefined, ...props }), jsx("span", { className: styles$
|
|
231
|
+
.join(' ') || undefined, ...props }), jsx("span", { className: styles$1b.checkbox, children: indeterminate ? jsx(IndeterminateIcon, {}) : jsx(CheckIcon$1, {}) })] }), label && jsx("span", { className: styles$1b.labelText, children: label })] }), error && (jsx("span", { id: errorId, className: styles$1b.errorText, children: error })), helperText && !error && (jsx("span", { id: helperId, className: styles$1b.helperText, children: helperText }))] }));
|
|
232
232
|
});
|
|
233
233
|
Checkbox.displayName = 'Checkbox';
|
|
234
234
|
|
|
235
|
-
var styles$
|
|
235
|
+
var styles$1a = {"wrapper":"Datepicker-module_wrapper__SdezU","fullWidth":"Datepicker-module_fullWidth__CAeMt","label":"Datepicker-module_label__qUNBV","inputWrapper":"Datepicker-module_inputWrapper__FK2IJ","sm":"Datepicker-module_sm__DuDMB","md":"Datepicker-module_md__oyus3","lg":"Datepicker-module_lg__2sqBg","icon":"Datepicker-module_icon__WdaRf","input":"Datepicker-module_input__4TCcy","disabled":"Datepicker-module_disabled__W0e-a","error":"Datepicker-module_error__XPpIy","helperText":"Datepicker-module_helperText__UllZP","errorText":"Datepicker-module_errorText__lveyr"};
|
|
236
236
|
|
|
237
237
|
const CalendarIcon = () => (jsxs("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: [jsx("rect", { x: "3", y: "4", width: "18", height: "18", rx: "2", ry: "2" }), jsx("line", { x1: "16", y1: "2", x2: "16", y2: "6" }), jsx("line", { x1: "8", y1: "2", x2: "8", y2: "6" }), jsx("line", { x1: "3", y1: "10", x2: "21", y2: "10" })] }));
|
|
238
238
|
/**
|
|
@@ -244,23 +244,23 @@ const Datepicker = forwardRef(({ size = 'md', label, helperText, error, fullWidt
|
|
|
244
244
|
const helperId = `${inputId}-helper`;
|
|
245
245
|
const errorId = `${inputId}-error`;
|
|
246
246
|
const wrapperClasses = [
|
|
247
|
-
styles$
|
|
248
|
-
fullWidth ? styles$
|
|
247
|
+
styles$1a.wrapper,
|
|
248
|
+
fullWidth ? styles$1a.fullWidth : '',
|
|
249
249
|
className,
|
|
250
250
|
].filter(Boolean).join(' ');
|
|
251
251
|
const inputWrapperClasses = [
|
|
252
|
-
styles$
|
|
253
|
-
styles$
|
|
254
|
-
error ? styles$
|
|
255
|
-
disabled ? styles$
|
|
252
|
+
styles$1a.inputWrapper,
|
|
253
|
+
styles$1a[size],
|
|
254
|
+
error ? styles$1a.error : '',
|
|
255
|
+
disabled ? styles$1a.disabled : '',
|
|
256
256
|
].filter(Boolean).join(' ');
|
|
257
|
-
return (jsxs("div", { className: wrapperClasses, children: [label && (jsx("label", { htmlFor: inputId, className: styles$
|
|
257
|
+
return (jsxs("div", { className: wrapperClasses, children: [label && (jsx("label", { htmlFor: inputId, className: styles$1a.label, children: label })), jsxs("div", { className: inputWrapperClasses, children: [jsx("span", { className: styles$1a.icon, children: jsx(CalendarIcon, {}) }), jsx("input", { ref: ref, type: "date", id: inputId, className: styles$1a.input, disabled: disabled, "aria-invalid": !!error, "aria-describedby": [error ? errorId : null, helperText ? helperId : null]
|
|
258
258
|
.filter(Boolean)
|
|
259
|
-
.join(' ') || undefined, ...props })] }), error && (jsx("span", { id: errorId, className: styles$
|
|
259
|
+
.join(' ') || undefined, ...props })] }), error && (jsx("span", { id: errorId, className: styles$1a.errorText, children: error })), helperText && !error && (jsx("span", { id: helperId, className: styles$1a.helperText, children: helperText }))] }));
|
|
260
260
|
});
|
|
261
261
|
Datepicker.displayName = 'Datepicker';
|
|
262
262
|
|
|
263
|
-
var styles$
|
|
263
|
+
var styles$19 = {"wrapper":"Input-module_wrapper__-8ija","fullWidth":"Input-module_fullWidth__xXOvN","label":"Input-module_label__t4LH-","inputWrapper":"Input-module_inputWrapper__U4EEd","error":"Input-module_error__fT9Sb","disabled":"Input-module_disabled__3tnIE","xs":"Input-module_xs__p7BuD","sm":"Input-module_sm__lGHP-","md":"Input-module_md__pReoW","lg":"Input-module_lg__iqqov","input":"Input-module_input__PeHY6","icon":"Input-module_icon__jkJiF","textarea":"Input-module_textarea__ZgdBz","helperText":"Input-module_helperText__eKsC8","errorText":"Input-module_errorText__xoiKP"};
|
|
264
264
|
|
|
265
265
|
/**
|
|
266
266
|
* Input component for text entry.
|
|
@@ -268,45 +268,45 @@ var styles$17 = {"wrapper":"Input-module_wrapper__-8ija","fullWidth":"Input-modu
|
|
|
268
268
|
const Input = forwardRef(({ size = 'md', label, helperText, error, leftIcon, rightIcon, fullWidth = false, className = '', id, disabled, ...props }, ref) => {
|
|
269
269
|
const inputId = id || `input-${Math.random().toString(36).substr(2, 9)}`;
|
|
270
270
|
const wrapperClasses = [
|
|
271
|
-
styles$
|
|
272
|
-
fullWidth ? styles$
|
|
271
|
+
styles$19.wrapper,
|
|
272
|
+
fullWidth ? styles$19.fullWidth : '',
|
|
273
273
|
className,
|
|
274
274
|
]
|
|
275
275
|
.filter(Boolean)
|
|
276
276
|
.join(' ');
|
|
277
277
|
const inputWrapperClasses = [
|
|
278
|
-
styles$
|
|
279
|
-
styles$
|
|
280
|
-
error ? styles$
|
|
281
|
-
disabled ? styles$
|
|
278
|
+
styles$19.inputWrapper,
|
|
279
|
+
styles$19[size],
|
|
280
|
+
error ? styles$19.error : '',
|
|
281
|
+
disabled ? styles$19.disabled : '',
|
|
282
282
|
]
|
|
283
283
|
.filter(Boolean)
|
|
284
284
|
.join(' ');
|
|
285
|
-
return (jsxs("div", { className: wrapperClasses, children: [label && (jsx("label", { htmlFor: inputId, className: styles$
|
|
285
|
+
return (jsxs("div", { className: wrapperClasses, children: [label && (jsx("label", { htmlFor: inputId, className: styles$19.label, children: label })), jsxs("div", { className: inputWrapperClasses, children: [leftIcon && jsx("span", { className: styles$19.icon, children: leftIcon }), jsx("input", { ref: ref, id: inputId, className: styles$19.input, disabled: disabled, "aria-invalid": !!error, "aria-describedby": error ? `${inputId}-error` : helperText ? `${inputId}-helper` : undefined, ...props }), rightIcon && jsx("span", { className: styles$19.icon, children: rightIcon })] }), error && (jsx("span", { id: `${inputId}-error`, className: styles$19.errorText, children: error })), helperText && !error && (jsx("span", { id: `${inputId}-helper`, className: styles$19.helperText, children: helperText }))] }));
|
|
286
286
|
});
|
|
287
287
|
Input.displayName = 'Input';
|
|
288
288
|
const Textarea = forwardRef(({ size = 'md', label, helperText, error, fullWidth = false, className = '', id, disabled, rows = 4, ...props }, ref) => {
|
|
289
289
|
const textareaId = id || `textarea-${Math.random().toString(36).substr(2, 9)}`;
|
|
290
290
|
const wrapperClasses = [
|
|
291
|
-
styles$
|
|
292
|
-
fullWidth ? styles$
|
|
291
|
+
styles$19.wrapper,
|
|
292
|
+
fullWidth ? styles$19.fullWidth : '',
|
|
293
293
|
className,
|
|
294
294
|
]
|
|
295
295
|
.filter(Boolean)
|
|
296
296
|
.join(' ');
|
|
297
297
|
const textareaClasses = [
|
|
298
|
-
styles$
|
|
299
|
-
styles$
|
|
300
|
-
error ? styles$
|
|
301
|
-
disabled ? styles$
|
|
298
|
+
styles$19.textarea,
|
|
299
|
+
styles$19[size],
|
|
300
|
+
error ? styles$19.error : '',
|
|
301
|
+
disabled ? styles$19.disabled : '',
|
|
302
302
|
]
|
|
303
303
|
.filter(Boolean)
|
|
304
304
|
.join(' ');
|
|
305
|
-
return (jsxs("div", { className: wrapperClasses, children: [label && (jsx("label", { htmlFor: textareaId, className: styles$
|
|
305
|
+
return (jsxs("div", { className: wrapperClasses, children: [label && (jsx("label", { htmlFor: textareaId, className: styles$19.label, children: label })), jsx("textarea", { ref: ref, id: textareaId, className: textareaClasses, disabled: disabled, rows: rows, "aria-invalid": !!error, "aria-describedby": error ? `${textareaId}-error` : helperText ? `${textareaId}-helper` : undefined, ...props }), error && (jsx("span", { id: `${textareaId}-error`, className: styles$19.errorText, children: error })), helperText && !error && (jsx("span", { id: `${textareaId}-helper`, className: styles$19.helperText, children: helperText }))] }));
|
|
306
306
|
});
|
|
307
307
|
Textarea.displayName = 'Textarea';
|
|
308
308
|
|
|
309
|
-
var styles$
|
|
309
|
+
var styles$18 = {"metric":"Metric-module_metric__LZ8D-","dark":"Metric-module_dark__FKdvj","clickable":"Metric-module_clickable__c3-pM","content":"Metric-module_content__YYpBG","valueRow":"Metric-module_valueRow__JpgYR","valueContainer":"Metric-module_valueContainer__CzjZ1","prefix":"Metric-module_prefix__Agpzq","value":"Metric-module_value__zspnf","suffix":"Metric-module_suffix__qvCMJ","warningIcon":"Metric-module_warningIcon__F-Ol5","label":"Metric-module_label__ydcti"};
|
|
310
310
|
|
|
311
311
|
const WarningIcon = () => (jsx("svg", { width: "24", height: "24", viewBox: "0 0 24 24", fill: "currentColor", children: jsx("path", { d: "M12 2L1 21h22L12 2zm0 3.5L19.5 19H4.5L12 5.5zM11 10v4h2v-4h-2zm0 6v2h2v-2h-2z" }) }));
|
|
312
312
|
/**
|
|
@@ -316,15 +316,15 @@ const WarningIcon = () => (jsx("svg", { width: "24", height: "24", viewBox: "0 0
|
|
|
316
316
|
const Metric = ({ value, label, prefix, suffix, dark = false, onClick, className = '', warning = false, }) => {
|
|
317
317
|
const displayValue = value !== undefined && !isNaN(parseFloat(String(value))) ? value : 0;
|
|
318
318
|
return (jsx("div", { className: `
|
|
319
|
-
${styles$
|
|
320
|
-
${dark ? styles$
|
|
321
|
-
${onClick ? styles$
|
|
319
|
+
${styles$18.metric}
|
|
320
|
+
${dark ? styles$18.dark : ''}
|
|
321
|
+
${onClick ? styles$18.clickable : ''}
|
|
322
322
|
${className}
|
|
323
|
-
`, onClick: onClick, children: value !== undefined && (jsxs("div", { className: styles$
|
|
323
|
+
`, onClick: onClick, children: value !== undefined && (jsxs("div", { className: styles$18.content, children: [jsxs("div", { className: styles$18.valueRow, children: [jsxs("div", { className: styles$18.valueContainer, children: [prefix && jsx("span", { className: styles$18.prefix, children: prefix }), jsx("span", { className: styles$18.value, children: displayValue }), suffix && jsx("span", { className: styles$18.suffix, children: suffix })] }), warning && (jsx("div", { className: styles$18.warningIcon, children: jsx(WarningIcon, {}) }))] }), jsx("div", { className: styles$18.label, children: label })] })) }));
|
|
324
324
|
};
|
|
325
325
|
Metric.displayName = 'Metric';
|
|
326
326
|
|
|
327
|
-
var styles$
|
|
327
|
+
var styles$17 = {"wrapper":"Select-module_wrapper__UN2Bo","fullWidth":"Select-module_fullWidth__GgV-D","label":"Select-module_label__aSRVE","selectWrapper":"Select-module_selectWrapper__OCGYf","sm":"Select-module_sm__oTHGX","md":"Select-module_md__VSZQg","lg":"Select-module_lg__nknhY","select":"Select-module_select__DY-Id","hasLeftIcon":"Select-module_hasLeftIcon__ZrReQ","leftIcon":"Select-module_leftIcon__nBU1-","chevron":"Select-module_chevron__1MAEQ","disabled":"Select-module_disabled__0GOXE","error":"Select-module_error__Yijk5","helperText":"Select-module_helperText__rHrqP","errorText":"Select-module_errorText__1kM2R"};
|
|
328
328
|
|
|
329
329
|
const ChevronDownIcon = () => (jsx("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: jsx("polyline", { points: "6 9 12 15 18 9" }) }));
|
|
330
330
|
/**
|
|
@@ -336,16 +336,16 @@ const Select = forwardRef(({ options, optionGroups, size = 'md', label, placehol
|
|
|
336
336
|
const helperId = `${selectId}-helper`;
|
|
337
337
|
const errorId = `${selectId}-error`;
|
|
338
338
|
const wrapperClasses = [
|
|
339
|
-
styles$
|
|
340
|
-
fullWidth ? styles$
|
|
339
|
+
styles$17.wrapper,
|
|
340
|
+
fullWidth ? styles$17.fullWidth : '',
|
|
341
341
|
className,
|
|
342
342
|
].filter(Boolean).join(' ');
|
|
343
343
|
const selectWrapperClasses = [
|
|
344
|
-
styles$
|
|
345
|
-
styles$
|
|
346
|
-
error ? styles$
|
|
347
|
-
disabled ? styles$
|
|
348
|
-
leftIcon ? styles$
|
|
344
|
+
styles$17.selectWrapper,
|
|
345
|
+
styles$17[size],
|
|
346
|
+
error ? styles$17.error : '',
|
|
347
|
+
disabled ? styles$17.disabled : '',
|
|
348
|
+
leftIcon ? styles$17.hasLeftIcon : '',
|
|
349
349
|
].filter(Boolean).join(' ');
|
|
350
350
|
const renderOptions = () => {
|
|
351
351
|
// Render grouped options
|
|
@@ -358,19 +358,19 @@ const Select = forwardRef(({ options, optionGroups, size = 'md', label, placehol
|
|
|
358
358
|
}
|
|
359
359
|
return null;
|
|
360
360
|
};
|
|
361
|
-
return (jsxs("div", { className: wrapperClasses, children: [label && (jsx("label", { htmlFor: selectId, className: styles$
|
|
361
|
+
return (jsxs("div", { className: wrapperClasses, children: [label && (jsx("label", { htmlFor: selectId, className: styles$17.label, children: label })), jsxs("div", { className: selectWrapperClasses, children: [leftIcon && jsx("span", { className: styles$17.leftIcon, children: leftIcon }), jsxs("select", { ref: ref, id: selectId, className: styles$17.select, disabled: disabled, "aria-invalid": !!error, "aria-describedby": [error ? errorId : null, helperText ? helperId : null]
|
|
362
362
|
.filter(Boolean)
|
|
363
|
-
.join(' ') || undefined, ...props, children: [placeholder && (jsx("option", { value: "", disabled: true, children: placeholder })), renderOptions()] }), jsx("span", { className: styles$
|
|
363
|
+
.join(' ') || undefined, ...props, children: [placeholder && (jsx("option", { value: "", disabled: true, children: placeholder })), renderOptions()] }), jsx("span", { className: styles$17.chevron, children: jsx(ChevronDownIcon, {}) })] }), error && (jsx("span", { id: errorId, className: styles$17.errorText, children: error })), helperText && !error && (jsx("span", { id: helperId, className: styles$17.helperText, children: helperText }))] }));
|
|
364
364
|
});
|
|
365
365
|
Select.displayName = 'Select';
|
|
366
366
|
|
|
367
|
-
var styles$
|
|
367
|
+
var styles$16 = {"spinner":"Spinner-module_spinner__OZwmB","svg":"Spinner-module_svg__Tusqk","spin":"Spinner-module_spin__YAPc9","track":"Spinner-module_track__NxLfV","indicator":"Spinner-module_indicator__gSUxF","xs":"Spinner-module_xs__4-WEg","sm":"Spinner-module_sm__enoDn","md":"Spinner-module_md__6axf9","lg":"Spinner-module_lg__EvJyC","xl":"Spinner-module_xl__yIXoK","srOnly":"Spinner-module_srOnly__WnZYf"};
|
|
368
368
|
|
|
369
369
|
const Spinner = ({ size = 'md', className = '', color, label = 'Loading...', }) => {
|
|
370
|
-
return (jsxs("span", { className: `${styles$
|
|
370
|
+
return (jsxs("span", { className: `${styles$16.spinner} ${styles$16[size]} ${className}`, role: "status", "aria-label": label, style: color ? { color } : undefined, children: [jsxs("svg", { className: styles$16.svg, xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", children: [jsx("circle", { className: styles$16.track, cx: "12", cy: "12", r: "10", stroke: "currentColor", strokeWidth: "4" }), jsx("path", { className: styles$16.indicator, fill: "currentColor", d: "M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z" })] }), jsx("span", { className: styles$16.srOnly, children: label })] }));
|
|
371
371
|
};
|
|
372
372
|
|
|
373
|
-
var styles$
|
|
373
|
+
var styles$15 = {"badge":"StatusBadge-module_badge__-BwEk","ticketed":"StatusBadge-module_ticketed__AJVZM","itinerary":"StatusBadge-module_itinerary__yRFNy","not-ticketed":"StatusBadge-module_not-ticketed__76GXg","submitted":"StatusBadge-module_submitted__QW0LL","pending":"StatusBadge-module_pending__FpMYC","cancelled":"StatusBadge-module_cancelled__XRz4S"};
|
|
374
374
|
|
|
375
375
|
const statusLabels = {
|
|
376
376
|
ticketed: 'Ticketed',
|
|
@@ -382,20 +382,20 @@ const statusLabels = {
|
|
|
382
382
|
};
|
|
383
383
|
const StatusBadge = ({ status, label, className, }) => {
|
|
384
384
|
const displayLabel = label || statusLabels[status] || status;
|
|
385
|
-
return (jsx("span", { className: `${styles$
|
|
385
|
+
return (jsx("span", { className: `${styles$15.badge} ${styles$15[status]} ${className || ''}`, "data-status": status, children: displayLabel }));
|
|
386
386
|
};
|
|
387
387
|
|
|
388
|
-
var styles$
|
|
388
|
+
var styles$14 = {"tag":"Tag-module_tag__uQVQa","content":"Tag-module_content__Z5bK9","sm":"Tag-module_sm__DvKJV","md":"Tag-module_md__KTo2m","lg":"Tag-module_lg__8xhWB","default":"Tag-module_default__5-uQz","primary":"Tag-module_primary__lwwYl","success":"Tag-module_success__kl3II","warning":"Tag-module_warning__peZRm","error":"Tag-module_error__6xzkl","info":"Tag-module_info__eKYiV","clickable":"Tag-module_clickable__TyiNK","removeButton":"Tag-module_removeButton__peMwo","removeIcon":"Tag-module_removeIcon__dQyJZ"};
|
|
389
389
|
|
|
390
390
|
const Tag = ({ children, variant = 'default', size = 'md', removable = false, onRemove, onClick, className = '', style, }) => {
|
|
391
391
|
const isClickable = Boolean(onClick);
|
|
392
|
-
return (jsxs("span", { className: `${styles$
|
|
392
|
+
return (jsxs("span", { className: `${styles$14.tag} ${styles$14[variant]} ${styles$14[size]} ${isClickable ? styles$14.clickable : ''} ${className}`, onClick: onClick, style: style, role: isClickable ? 'button' : undefined, tabIndex: isClickable ? 0 : undefined, children: [jsx("span", { className: styles$14.content, children: children }), removable && (jsx("button", { type: "button", className: styles$14.removeButton, onClick: (e) => {
|
|
393
393
|
e.stopPropagation();
|
|
394
394
|
onRemove?.();
|
|
395
|
-
}, "aria-label": "Remove", children: jsx("svg", { className: styles$
|
|
395
|
+
}, "aria-label": "Remove", children: jsx("svg", { className: styles$14.removeIcon, fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M6 18L18 6M6 6l12 12" }) }) }))] }));
|
|
396
396
|
};
|
|
397
397
|
|
|
398
|
-
var styles$
|
|
398
|
+
var styles$13 = {"wrapper":"Timepicker-module_wrapper__pPrwn","fullWidth":"Timepicker-module_fullWidth__de3hO","label":"Timepicker-module_label__5RDrm","inputWrapper":"Timepicker-module_inputWrapper__-E5pk","sm":"Timepicker-module_sm__sWJu2","md":"Timepicker-module_md__TfpGX","lg":"Timepicker-module_lg__xSlw-","icon":"Timepicker-module_icon__NuPk4","input":"Timepicker-module_input__NxTmR","disabled":"Timepicker-module_disabled__lyxzF","error":"Timepicker-module_error__TOMK7","helperText":"Timepicker-module_helperText__MmcqS","errorText":"Timepicker-module_errorText__pXdnE"};
|
|
399
399
|
|
|
400
400
|
const ClockIcon = () => (jsxs("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: [jsx("circle", { cx: "12", cy: "12", r: "10" }), jsx("polyline", { points: "12 6 12 12 16 14" })] }));
|
|
401
401
|
/**
|
|
@@ -407,34 +407,34 @@ const Timepicker = forwardRef(({ size = 'md', label, helperText, error, fullWidt
|
|
|
407
407
|
const helperId = `${inputId}-helper`;
|
|
408
408
|
const errorId = `${inputId}-error`;
|
|
409
409
|
const wrapperClasses = [
|
|
410
|
-
styles$
|
|
411
|
-
fullWidth ? styles$
|
|
410
|
+
styles$13.wrapper,
|
|
411
|
+
fullWidth ? styles$13.fullWidth : '',
|
|
412
412
|
className,
|
|
413
413
|
].filter(Boolean).join(' ');
|
|
414
414
|
const inputWrapperClasses = [
|
|
415
|
-
styles$
|
|
416
|
-
styles$
|
|
417
|
-
error ? styles$
|
|
418
|
-
disabled ? styles$
|
|
415
|
+
styles$13.inputWrapper,
|
|
416
|
+
styles$13[size],
|
|
417
|
+
error ? styles$13.error : '',
|
|
418
|
+
disabled ? styles$13.disabled : '',
|
|
419
419
|
].filter(Boolean).join(' ');
|
|
420
|
-
return (jsxs("div", { className: wrapperClasses, children: [label && (jsx("label", { htmlFor: inputId, className: styles$
|
|
420
|
+
return (jsxs("div", { className: wrapperClasses, children: [label && (jsx("label", { htmlFor: inputId, className: styles$13.label, children: label })), jsxs("div", { className: inputWrapperClasses, children: [jsx("span", { className: styles$13.icon, children: jsx(ClockIcon, {}) }), jsx("input", { ref: ref, type: "time", id: inputId, className: styles$13.input, disabled: disabled, "aria-invalid": !!error, "aria-describedby": [error ? errorId : null, helperText ? helperId : null]
|
|
421
421
|
.filter(Boolean)
|
|
422
|
-
.join(' ') || undefined, ...props })] }), error && (jsx("span", { id: errorId, className: styles$
|
|
422
|
+
.join(' ') || undefined, ...props })] }), error && (jsx("span", { id: errorId, className: styles$13.errorText, children: error })), helperText && !error && (jsx("span", { id: helperId, className: styles$13.helperText, children: helperText }))] }));
|
|
423
423
|
});
|
|
424
424
|
Timepicker.displayName = 'Timepicker';
|
|
425
425
|
|
|
426
|
-
var styles$
|
|
426
|
+
var styles$12 = {"title":"Title-module_title__mSSqn","light":"Title-module_light__7mlh-","normal":"Title-module_normal__ZYrS4","medium":"Title-module_medium__UK-Bj","semibold":"Title-module_semibold__07lTs","bold":"Title-module_bold__-oWUS"};
|
|
427
427
|
|
|
428
428
|
/**
|
|
429
429
|
* Title component for page headings.
|
|
430
430
|
* Large, prominent text for page titles.
|
|
431
431
|
*/
|
|
432
432
|
const Title = ({ children, weight = 'light', className = '', }) => {
|
|
433
|
-
return (jsx("h1", { className: `${styles$
|
|
433
|
+
return (jsx("h1", { className: `${styles$12.title} ${styles$12[weight]} ${className}`, children: children }));
|
|
434
434
|
};
|
|
435
435
|
Title.displayName = 'Title';
|
|
436
436
|
|
|
437
|
-
var styles
|
|
437
|
+
var styles$11 = {"toggle":"Toggle-module_toggle__lRFvk","checked":"Toggle-module_checked__duOWU","disabled":"Toggle-module_disabled__DV2FB","thumb":"Toggle-module_thumb__ehIbb","sm":"Toggle-module_sm__Gs9bK","md":"Toggle-module_md__hTNCY","lg":"Toggle-module_lg__DpHtS","wrapper":"Toggle-module_wrapper__-Bvff","wrapperDisabled":"Toggle-module_wrapperDisabled__ZSCvM","label":"Toggle-module_label__GeuIf"};
|
|
438
438
|
|
|
439
439
|
const Toggle = ({ checked, onChange, disabled = false, size = 'md', label, labelPosition = 'right', className = '', 'aria-label': ariaLabel, }) => {
|
|
440
440
|
const handleClick = () => {
|
|
@@ -448,14 +448,14 @@ const Toggle = ({ checked, onChange, disabled = false, size = 'md', label, label
|
|
|
448
448
|
onChange?.(!checked);
|
|
449
449
|
}
|
|
450
450
|
};
|
|
451
|
-
const toggleElement = (jsx("div", { className: `${styles
|
|
451
|
+
const toggleElement = (jsx("div", { className: `${styles$11.toggle} ${styles$11[size]} ${checked ? styles$11.checked : ''} ${disabled ? styles$11.disabled : ''} ${className}`, onClick: handleClick, onKeyDown: handleKeyDown, role: "switch", "aria-checked": checked, "aria-disabled": disabled, "aria-label": ariaLabel || label, tabIndex: disabled ? -1 : 0, children: jsx("span", { className: styles$11.thumb }) }));
|
|
452
452
|
if (label) {
|
|
453
|
-
return (jsxs("label", { className: `${styles
|
|
453
|
+
return (jsxs("label", { className: `${styles$11.wrapper} ${disabled ? styles$11.wrapperDisabled : ''}`, children: [labelPosition === 'left' && jsx("span", { className: styles$11.label, children: label }), toggleElement, labelPosition === 'right' && jsx("span", { className: styles$11.label, children: label })] }));
|
|
454
454
|
}
|
|
455
455
|
return toggleElement;
|
|
456
456
|
};
|
|
457
457
|
|
|
458
|
-
var styles$
|
|
458
|
+
var styles$10 = {"wrapper":"Tooltip-module_wrapper__9SUwl","tooltip":"Tooltip-module_tooltip__KQ7km","fadeIn":"Tooltip-module_fadeIn__dL8S5","content":"Tooltip-module_content__kO8yx","dark":"Tooltip-module_dark__Y66ss","light":"Tooltip-module_light__mItfR","semantic":"Tooltip-module_semantic__shhec","primary":"Tooltip-module_primary__no1LJ","secondary":"Tooltip-module_secondary__HEoKK","success":"Tooltip-module_success__EG2f-","warning":"Tooltip-module_warning__1zoqE","error":"Tooltip-module_error__Nn6y6","top":"Tooltip-module_top__1jrIn","bottom":"Tooltip-module_bottom__99YBc","left":"Tooltip-module_left__ZNd1H","right":"Tooltip-module_right__r0j5Q","arrow":"Tooltip-module_arrow__qcKWx","arrowTop":"Tooltip-module_arrowTop__k13dt","arrowBottom":"Tooltip-module_arrowBottom__FP-w2","arrowLeft":"Tooltip-module_arrowLeft__7T1uO","arrowRight":"Tooltip-module_arrowRight__FbPdB"};
|
|
459
459
|
|
|
460
460
|
const Tooltip = ({ content, children, position = 'top', variant = 'dark', delay = 200, disabled = false, className = '', }) => {
|
|
461
461
|
const [isVisible, setIsVisible] = useState(false);
|
|
@@ -533,10 +533,10 @@ const Tooltip = ({ content, children, position = 'top', variant = 'dark', delay
|
|
|
533
533
|
}
|
|
534
534
|
};
|
|
535
535
|
}, []);
|
|
536
|
-
return (jsxs("div", { ref: triggerRef, className: `${styles$
|
|
536
|
+
return (jsxs("div", { ref: triggerRef, className: `${styles$10.wrapper} ${className}`, onMouseEnter: handleMouseEnter, onMouseLeave: handleMouseLeave, onFocus: handleFocus, onBlur: handleBlur, onTouchStart: handleTouchStart, onTouchEnd: handleTouchEnd, children: [children, isVisible && content && (jsxs("div", { ref: tooltipRef, className: `${styles$10.tooltip} ${styles$10[actualPosition]} ${styles$10[variant]} ${!['dark', 'light'].includes(variant) ? styles$10.semantic : ''}`, role: "tooltip", children: [jsx("div", { className: styles$10.content, children: content }), jsx("div", { className: `${styles$10.arrow} ${styles$10[`arrow${actualPosition.charAt(0).toUpperCase()}${actualPosition.slice(1)}`]}` })] }))] }));
|
|
537
537
|
};
|
|
538
538
|
|
|
539
|
-
var styles
|
|
539
|
+
var styles$$ = {"service":"TravelServiceIcon-module_service__-4EZb","code":"TravelServiceIcon-module_code__vElzI","multi":"TravelServiceIcon-module_multi__nqZLM","multiIndicator":"TravelServiceIcon-module_multiIndicator__KJF1L"};
|
|
540
540
|
|
|
541
541
|
// Airline brand colors
|
|
542
542
|
const vendorColors = {
|
|
@@ -576,16 +576,16 @@ const TravelServiceIcon = ({ type, vendor, mode = 'icon', size = 28, multi = fal
|
|
|
576
576
|
const colors = mode === 'icon' && vendorColors[vendorKey]
|
|
577
577
|
? vendorColors[vendorKey]
|
|
578
578
|
: typeColors$1[type] || typeColors$1.U;
|
|
579
|
-
return (jsxs("span", { className: `${styles
|
|
579
|
+
return (jsxs("span", { className: `${styles$$.service} ${multi ? styles$$.multi : ''} ${className || ''}`, style: {
|
|
580
580
|
width: size,
|
|
581
581
|
height: size,
|
|
582
582
|
backgroundColor: colors.bg,
|
|
583
583
|
color: colors.fg,
|
|
584
584
|
fontSize: size * 0.4,
|
|
585
|
-
}, title: vendor ? `${vendor} (${type})` : type, children: [mode === 'code' && vendor ? (jsx("span", { className: styles
|
|
585
|
+
}, title: vendor ? `${vendor} (${type})` : type, children: [mode === 'code' && vendor ? (jsx("span", { className: styles$$.code, children: vendor })) : (jsx("svg", { viewBox: "0 0 24 24", width: size * 0.55, height: size * 0.55, fill: "currentColor", children: typeIcons$1[type] || typeIcons$1.U })), multi && jsx("span", { className: styles$$.multiIndicator, children: "+" })] }));
|
|
586
586
|
};
|
|
587
587
|
|
|
588
|
-
var styles$
|
|
588
|
+
var styles$_ = {"icon":"TypeIcon-module_icon__WUL-x"};
|
|
589
589
|
|
|
590
590
|
const typeLabels = {
|
|
591
591
|
A: 'Air',
|
|
@@ -618,7 +618,7 @@ const typeIcons = {
|
|
|
618
618
|
const TypeIcon = ({ type, size = 18, showTooltip = true, className, }) => {
|
|
619
619
|
const colors = typeColors[type] || typeColors.U;
|
|
620
620
|
const label = typeLabels[type] || 'Unknown';
|
|
621
|
-
return (jsx("span", { className: `${styles$
|
|
621
|
+
return (jsx("span", { className: `${styles$_.icon} ${className || ''}`, style: {
|
|
622
622
|
width: size,
|
|
623
623
|
height: size,
|
|
624
624
|
backgroundColor: colors.bg,
|
|
@@ -626,7 +626,7 @@ const TypeIcon = ({ type, size = 18, showTooltip = true, className, }) => {
|
|
|
626
626
|
}, title: showTooltip ? label : undefined, "aria-label": label, children: jsx("svg", { viewBox: "0 0 24 24", width: size * 0.6, height: size * 0.6, fill: "currentColor", children: typeIcons[type] || typeIcons.U }) }));
|
|
627
627
|
};
|
|
628
628
|
|
|
629
|
-
var styles$
|
|
629
|
+
var styles$Z = {"accordion":"Accordion-module_accordion__I3hmS","headerContainer":"Accordion-module_headerContainer__QhfHx","toggle":"Accordion-module_toggle__rlK5n","caret":"Accordion-module_caret__iZAh1","open":"Accordion-module_open__5jX-w","header":"Accordion-module_header__gzKrn","body":"Accordion-module_body__xTgL6","hidden":"Accordion-module_hidden__wcCWd","visible":"Accordion-module_visible__116om","timeline":"Accordion-module_timeline__ikrdK","line":"Accordion-module_line__buDP1","endCaret":"Accordion-module_endCaret__OXpPJ","content":"Accordion-module_content__aL8Vn"};
|
|
630
630
|
|
|
631
631
|
const CaretIcon = ({ className }) => (jsx("svg", { className: className, width: "20", height: "20", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: jsx("polyline", { points: "9 18 15 12 9 6" }) }));
|
|
632
632
|
/**
|
|
@@ -644,21 +644,21 @@ const Accordion = ({ header, children, defaultOpen = true, open: controlledOpen,
|
|
|
644
644
|
}
|
|
645
645
|
onOpenChange?.(newOpen);
|
|
646
646
|
};
|
|
647
|
-
return (jsxs("div", { className: `${styles$
|
|
647
|
+
return (jsxs("div", { className: `${styles$Z.accordion} ${className || ''}`, children: [jsxs("div", { className: styles$Z.headerContainer, children: [jsx("button", { type: "button", className: styles$Z.toggle, onClick: handleToggle, "aria-expanded": isOpen, children: jsx(CaretIcon, { className: `${styles$Z.caret} ${isOpen ? styles$Z.open : ''}` }) }), jsx("div", { className: styles$Z.header, children: header })] }), jsxs("div", { className: `${styles$Z.body} ${isOpen ? styles$Z.visible : styles$Z.hidden}`, "aria-hidden": !isOpen, children: [showTimeline && (jsxs("div", { className: styles$Z.timeline, children: [jsx("div", { className: styles$Z.line }), jsx(CaretIcon, { className: styles$Z.endCaret })] })), jsx("div", { className: styles$Z.content, children: children })] })] }));
|
|
648
648
|
};
|
|
649
649
|
Accordion.displayName = 'Accordion';
|
|
650
650
|
|
|
651
|
-
var styles$
|
|
651
|
+
var styles$Y = {"selector":"CalendarSelectors-module_selector__1nDos","item":"CalendarSelectors-module_item__CoR5s","active":"CalendarSelectors-module_active__u4w6Z","sm":"CalendarSelectors-module_sm__ju5t-","withLabel":"CalendarSelectors-module_withLabel__Jr9Re","md":"CalendarSelectors-module_md__a-U38","lg":"CalendarSelectors-module_lg__WHvAF","iconOnly":"CalendarSelectors-module_iconOnly__cAjyD"};
|
|
652
652
|
|
|
653
653
|
const ListIcon = () => (jsxs("svg", { width: "20", height: "20", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", "aria-hidden": "true", children: [jsx("line", { x1: "8", y1: "6", x2: "21", y2: "6" }), jsx("line", { x1: "8", y1: "12", x2: "21", y2: "12" }), jsx("line", { x1: "8", y1: "18", x2: "21", y2: "18" }), jsx("circle", { cx: "3", cy: "6", r: "1", fill: "currentColor", stroke: "none" }), jsx("circle", { cx: "3", cy: "12", r: "1", fill: "currentColor", stroke: "none" }), jsx("circle", { cx: "3", cy: "18", r: "1", fill: "currentColor", stroke: "none" })] }));
|
|
654
|
-
const SegmentedSelector = ({ options, value, onChange, disabled = false, size = 'md', className = '', ariaLabel = 'View options', dataTest, }) => (jsx("div", { className: [styles$
|
|
654
|
+
const SegmentedSelector = ({ options, value, onChange, disabled = false, size = 'md', className = '', ariaLabel = 'View options', dataTest, }) => (jsx("div", { className: [styles$Y.selector, className].filter(Boolean).join(' '), role: "group", "aria-label": ariaLabel, "data-test": dataTest, children: options.map((option) => {
|
|
655
655
|
const active = option.id === value;
|
|
656
656
|
const accessibleName = option.alt ?? option.label ?? option.id;
|
|
657
657
|
return (jsxs("button", { type: "button", title: accessibleName, "aria-label": accessibleName, "aria-pressed": active, disabled: disabled, "data-test": dataTest ? `${dataTest}-option-${option.id}` : undefined, className: [
|
|
658
|
-
styles$
|
|
659
|
-
styles$
|
|
660
|
-
option.label ? styles$
|
|
661
|
-
active ? styles$
|
|
658
|
+
styles$Y.item,
|
|
659
|
+
styles$Y[size],
|
|
660
|
+
option.label ? styles$Y.withLabel : styles$Y.iconOnly,
|
|
661
|
+
active ? styles$Y.active : '',
|
|
662
662
|
].filter(Boolean).join(' '), onClick: () => onChange?.(option.id), children: [option.icon, option.label && jsx("span", { children: option.label })] }, option.id));
|
|
663
663
|
}) }));
|
|
664
664
|
const CalendarViewSelector = ({ value, onChange, ...props }) => (jsx(SegmentedSelector, { ...props, ariaLabel: "Calendar view", dataTest: "calendar-view-selector", value: value, onChange: (nextValue) => onChange?.(nextValue), options: [
|
|
@@ -671,7 +671,7 @@ const CalendarTypeSelector = ({ value, onChange, ...props }) => (jsx(SegmentedSe
|
|
|
671
671
|
{ id: 'due_dates', label: 'Due Dates' },
|
|
672
672
|
] }));
|
|
673
673
|
|
|
674
|
-
var styles$
|
|
674
|
+
var styles$X = {"dropdown":"Dropdown-module_dropdown__K4-yz","arrow":"Dropdown-module_arrow__2Xuwf","arrowOpen":"Dropdown-module_arrowOpen__5g2iY","menu":"Dropdown-module_menu__dCgm8","menuOpen":"Dropdown-module_menuOpen__-IXFR","left":"Dropdown-module_left__tnNcS","center":"Dropdown-module_center__s9zhj","right":"Dropdown-module_right__s71gz","item":"Dropdown-module_item__R008o","itemDisabled":"Dropdown-module_itemDisabled__XIuNm","itemIcon":"Dropdown-module_itemIcon__DbSnD"};
|
|
675
675
|
|
|
676
676
|
const Dropdown = ({ label, children, alignment = 'left', width, className = '', disabled = false, }) => {
|
|
677
677
|
const [isOpen, setIsOpen] = useState(false);
|
|
@@ -694,14 +694,14 @@ const Dropdown = ({ label, children, alignment = 'left', width, className = '',
|
|
|
694
694
|
setIsOpen(false);
|
|
695
695
|
}
|
|
696
696
|
};
|
|
697
|
-
return (jsxs("div", { ref: dropdownRef, className: `${styles$
|
|
697
|
+
return (jsxs("div", { ref: dropdownRef, className: `${styles$X.dropdown} ${className}`, onKeyDown: handleKeyDown, children: [jsxs(Button, { variant: "secondary", onClick: () => !disabled && setIsOpen(!isOpen), disabled: disabled, "aria-expanded": isOpen, "aria-haspopup": "true", children: [label, jsx("svg", { className: `${styles$X.arrow} ${isOpen ? styles$X.arrowOpen : ''}`, fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", width: "16", height: "16", children: jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M19 9l-7 7-7-7" }) })] }), jsx("div", { className: `${styles$X.menu} ${styles$X[alignment]} ${isOpen ? styles$X.menuOpen : ''}`, style: width ? { minWidth: `${width}px` } : undefined, role: "menu", children: children })] }));
|
|
698
698
|
};
|
|
699
699
|
const DropdownItem = ({ children, onClick, disabled = false, icon, className = '', }) => {
|
|
700
|
-
return (jsxs("button", { type: "button", className: `${styles$
|
|
700
|
+
return (jsxs("button", { type: "button", className: `${styles$X.item} ${disabled ? styles$X.itemDisabled : ''} ${className}`, onClick: onClick, disabled: disabled, role: "menuitem", children: [icon && jsx("span", { className: styles$X.itemIcon, children: icon }), children] }));
|
|
701
701
|
};
|
|
702
702
|
Dropdown.Item = DropdownItem;
|
|
703
703
|
|
|
704
|
-
var styles$
|
|
704
|
+
var styles$W = {"wrapper":"FilterChip-module_wrapper__YDRSW","chip":"FilterChip-module_chip__pF7K5","open":"FilterChip-module_open__EYBp7","active":"FilterChip-module_active__JEkku","label":"FilterChip-module_label__tRr-y","value":"FilterChip-module_value__0EcVu","chevron":"FilterChip-module_chevron__kh13z","rotated":"FilterChip-module_rotated__U-FzI","dropdown":"FilterChip-module_dropdown__w3ytW","infoMessage":"FilterChip-module_infoMessage__0TzcA","searchWrapper":"FilterChip-module_searchWrapper__VHOSK","searchIcon":"FilterChip-module_searchIcon__jJ2K-","searchInput":"FilterChip-module_searchInput__FqwvR","optionsList":"FilterChip-module_optionsList__P0dgd","option":"FilterChip-module_option__DMuqM","selected":"FilterChip-module_selected__ltt9Y","noResults":"FilterChip-module_noResults__QGNao"};
|
|
705
705
|
|
|
706
706
|
const FilterChip = ({ label, value, options, onChange, searchable = false, searchPlaceholder = 'Search...', infoMessage, className, }) => {
|
|
707
707
|
const [open, setOpen] = useState(false);
|
|
@@ -738,13 +738,13 @@ const FilterChip = ({ label, value, options, onChange, searchable = false, searc
|
|
|
738
738
|
const selectedOption = options.find(opt => opt.value === value);
|
|
739
739
|
const displayValue = selectedOption?.label || value;
|
|
740
740
|
const isDefault = value === options[0]?.value;
|
|
741
|
-
return (jsxs("div", { ref: ref, className: `${styles$
|
|
741
|
+
return (jsxs("div", { ref: ref, className: `${styles$W.wrapper} ${className || ''}`, children: [jsxs("button", { type: "button", className: `${styles$W.chip} ${open ? styles$W.open : ''} ${!isDefault ? styles$W.active : ''}`, onClick: () => setOpen(!open), "aria-haspopup": "listbox", "aria-expanded": open, children: [jsxs("span", { className: styles$W.label, children: [label, ":"] }), jsx("span", { className: styles$W.value, children: displayValue }), jsx("svg", { className: `${styles$W.chevron} ${open ? styles$W.rotated : ''}`, width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: jsx("polyline", { points: "6 9 12 15 18 9" }) })] }), open && (jsxs("div", { className: styles$W.dropdown, role: "listbox", children: [infoMessage && (jsxs("div", { className: styles$W.infoMessage, children: [jsx("svg", { width: "12", height: "12", viewBox: "0 0 24 24", fill: "currentColor", children: jsx("path", { d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z" }) }), jsx("span", { children: infoMessage })] })), searchable && (jsxs("div", { className: styles$W.searchWrapper, children: [jsxs("svg", { className: styles$W.searchIcon, width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: [jsx("circle", { cx: "11", cy: "11", r: "8" }), jsx("line", { x1: "21", y1: "21", x2: "16.65", y2: "16.65" })] }), jsx("input", { type: "text", value: searchQuery, onChange: (e) => setSearchQuery(e.target.value), placeholder: searchPlaceholder, className: styles$W.searchInput, autoFocus: true })] })), jsxs("div", { className: styles$W.optionsList, children: [filteredOptions.map((option) => (jsx("button", { type: "button", role: "option", "aria-selected": option.value === value, className: `${styles$W.option} ${option.value === value ? styles$W.selected : ''}`, onClick: () => {
|
|
742
742
|
onChange(option.value);
|
|
743
743
|
setOpen(false);
|
|
744
|
-
}, children: option.label }, option.value))), filteredOptions.length === 0 && (jsx("div", { className: styles$
|
|
744
|
+
}, children: option.label }, option.value))), filteredOptions.length === 0 && (jsx("div", { className: styles$W.noResults, children: "No results found" }))] })] }))] }));
|
|
745
745
|
};
|
|
746
746
|
|
|
747
|
-
var styles$
|
|
747
|
+
var styles$V = {"formField":"FormField-module_formField__VhLhK","label":"FormField-module_label__CNCs6","required":"FormField-module_required__HkPQf","inputElement":"FormField-module_inputElement__9uvGR","inputError":"FormField-module_inputError__xD7fk","helperText":"FormField-module_helperText__D99kd","errorText":"FormField-module_errorText__8mXAJ","visuallyHidden":"FormField-module_visuallyHidden__YQc7S"};
|
|
748
748
|
|
|
749
749
|
const FormField = forwardRef(({ label, helperText, error, required = false, hideLabel = false, className, as = 'input', inputProps, textareaProps, children, }, ref) => {
|
|
750
750
|
const generatedId = useId();
|
|
@@ -763,15 +763,15 @@ const FormField = forwardRef(({ label, helperText, error, required = false, hide
|
|
|
763
763
|
return children;
|
|
764
764
|
}
|
|
765
765
|
if (as === 'textarea') {
|
|
766
|
-
return (jsx(Textarea, { ref: ref, id: inputId, "aria-describedby": describedBy, "aria-invalid": hasError, "aria-required": required, ...textareaProps, className: `${styles$
|
|
766
|
+
return (jsx(Textarea, { ref: ref, id: inputId, "aria-describedby": describedBy, "aria-invalid": hasError, "aria-required": required, ...textareaProps, className: `${styles$V.inputElement} ${hasError ? styles$V.inputError : ''} ${textareaProps?.className || ''}` }));
|
|
767
767
|
}
|
|
768
|
-
return (jsx(Input, { ref: ref, id: inputId, "aria-describedby": describedBy, "aria-invalid": hasError, "aria-required": required, ...inputProps, className: `${styles$
|
|
768
|
+
return (jsx(Input, { ref: ref, id: inputId, "aria-describedby": describedBy, "aria-invalid": hasError, "aria-required": required, ...inputProps, className: `${styles$V.inputElement} ${hasError ? styles$V.inputError : ''} ${inputProps?.className || ''}` }));
|
|
769
769
|
};
|
|
770
|
-
return (jsxs("div", { className: `${styles$
|
|
770
|
+
return (jsxs("div", { className: `${styles$V.formField} ${className || ''}`, children: [jsxs("label", { htmlFor: inputId, className: `${styles$V.label} ${hideLabel ? styles$V.visuallyHidden : ''}`, children: [label, required && jsx("span", { className: styles$V.required, "aria-hidden": "true", children: "*" })] }), renderInput(), helperText && !hasError && (jsx("p", { id: helperId, className: styles$V.helperText, children: helperText })), hasError && (jsx("p", { id: errorId, className: styles$V.errorText, role: "alert", children: error }))] }));
|
|
771
771
|
});
|
|
772
772
|
FormField.displayName = 'FormField';
|
|
773
773
|
|
|
774
|
-
var styles$
|
|
774
|
+
var styles$U = {"row":"FormRow-module_row__2ObP9","cols1":"FormRow-module_cols1__WsxX3","cols2":"FormRow-module_cols2__t548T","cols3":"FormRow-module_cols3__zjoSR","cols4":"FormRow-module_cols4__DbZL-","gapsm":"FormRow-module_gapsm__sl0ji","gapmd":"FormRow-module_gapmd__77Yp3","gaplg":"FormRow-module_gaplg__Yb-fh","stackMobile":"FormRow-module_stackMobile__6UluR"};
|
|
775
775
|
|
|
776
776
|
/**
|
|
777
777
|
* FormRow component for laying out form fields in a responsive grid.
|
|
@@ -781,16 +781,16 @@ const FormRow = ({ children, columns, gap = 'md', className, stackOnMobile = tru
|
|
|
781
781
|
const childCount = Children.count(children);
|
|
782
782
|
const colCount = columns || (childCount > 4 ? 4 : childCount);
|
|
783
783
|
return (jsx("div", { className: `
|
|
784
|
-
${styles$
|
|
785
|
-
${styles$
|
|
786
|
-
${styles$
|
|
787
|
-
${stackOnMobile ? styles$
|
|
784
|
+
${styles$U.row}
|
|
785
|
+
${styles$U[`cols${colCount}`]}
|
|
786
|
+
${styles$U[`gap${gap}`]}
|
|
787
|
+
${stackOnMobile ? styles$U.stackMobile : ''}
|
|
788
788
|
${className || ''}
|
|
789
789
|
`, children: children }));
|
|
790
790
|
};
|
|
791
791
|
FormRow.displayName = 'FormRow';
|
|
792
792
|
|
|
793
|
-
var styles$
|
|
793
|
+
var styles$T = {"section":"FormSection-module_section__T17Vg","header":"FormSection-module_header__2MkY6","icon":"FormSection-module_icon__uywPB","title":"FormSection-module_title__dlvYD","fieldset":"FormSection-module_fieldset__pDDIo","disabled":"FormSection-module_disabled__xC3-e","status":"FormSection-module_status__2XOyW","statusLabel":"FormSection-module_statusLabel__VAuDb","statusValue":"FormSection-module_statusValue__YKSc-","submitted":"FormSection-module_submitted__sS-zT","not-submitted":"FormSection-module_not-submitted__Kuk2i","draft":"FormSection-module_draft__XHq3-"};
|
|
794
794
|
|
|
795
795
|
/**
|
|
796
796
|
* FormSection component for grouping related form fields with a title and icon.
|
|
@@ -799,45 +799,45 @@ var styles$R = {"section":"FormSection-module_section__T17Vg","header":"FormSect
|
|
|
799
799
|
const FormSection = ({ title, icon, status, disabled = false, children, className, id, }) => {
|
|
800
800
|
const isSubmitted = status === 'submitted';
|
|
801
801
|
const isDisabled = disabled || isSubmitted;
|
|
802
|
-
return (jsxs("div", { className: `${styles$
|
|
802
|
+
return (jsxs("div", { className: `${styles$T.section} ${className || ''}`, id: id, children: [jsxs("div", { className: styles$T.header, children: [icon && jsx("span", { className: styles$T.icon, children: icon }), jsx("h2", { className: styles$T.title, children: title })] }), jsxs("fieldset", { disabled: isDisabled, className: `${styles$T.fieldset} ${isDisabled ? styles$T.disabled : ''}`, children: [status && (jsxs("div", { className: styles$T.status, children: [jsx("span", { className: styles$T.statusLabel, children: "Status:" }), jsx("span", { className: `${styles$T.statusValue} ${styles$T[status]}`, children: status === 'submitted' ? 'Submitted' : status === 'draft' ? 'Draft' : 'Not Submitted' })] })), children] })] }));
|
|
803
803
|
};
|
|
804
804
|
FormSection.displayName = 'FormSection';
|
|
805
805
|
|
|
806
|
-
var styles$
|
|
806
|
+
var styles$S = {"stack":"FormStack-module_stack__SURjY","sm":"FormStack-module_sm__rt3tb","md":"FormStack-module_md__SRDmc","lg":"FormStack-module_lg__jql3j"};
|
|
807
807
|
|
|
808
808
|
/** Standard vertical form-field rhythm used by Hub modal forms. */
|
|
809
|
-
const FormStack = ({ children, gap = 'md', className = '' }) => (jsx("div", { className: [styles$
|
|
809
|
+
const FormStack = ({ children, gap = 'md', className = '' }) => (jsx("div", { className: [styles$S.stack, styles$S[gap], className].filter(Boolean).join(' '), children: children }));
|
|
810
810
|
|
|
811
|
-
var styles$
|
|
811
|
+
var styles$R = {"toggle":"ManifestViewToggle-module_toggle__sHnAd","lockedToggle":"ManifestViewToggle-module_lockedToggle__m70h9","tab":"ManifestViewToggle-module_tab__qcwg7","active":"ManifestViewToggle-module_active__ln3B8","locked":"ManifestViewToggle-module_locked__Udun8","lockedActive":"ManifestViewToggle-module_lockedActive__kYSaF","count":"ManifestViewToggle-module_count__M-8a8"};
|
|
812
812
|
|
|
813
813
|
const ManifestViewToggle = ({ view, onView, paxCount, eqCount, locked, className = '', }) => {
|
|
814
814
|
const tabs = [
|
|
815
815
|
{ key: 'passengers', label: 'Passengers', count: paxCount, icon: UsersIcon$1 },
|
|
816
816
|
{ key: 'equipment', label: 'Equipment', count: eqCount, icon: CubeIcon },
|
|
817
817
|
];
|
|
818
|
-
return (jsx("div", { className: [styles$
|
|
818
|
+
return (jsx("div", { className: [styles$R.toggle, locked ? styles$R.lockedToggle : '', className].filter(Boolean).join(' '), role: "tablist", "aria-label": "Manifest view", children: tabs.map((tab) => {
|
|
819
819
|
const active = view === tab.key;
|
|
820
820
|
const Icon = locked ? LockIcon$1 : tab.icon;
|
|
821
821
|
return (jsxs("button", { type: "button", role: "tab", "aria-selected": active, onClick: () => onView(tab.key), className: [
|
|
822
|
-
styles$
|
|
823
|
-
active ? styles$
|
|
824
|
-
locked ? styles$
|
|
825
|
-
locked && active ? styles$
|
|
826
|
-
].filter(Boolean).join(' '), children: [jsx(Icon, { size: 16 }), tab.label, jsx("span", { className: styles$
|
|
822
|
+
styles$R.tab,
|
|
823
|
+
active ? styles$R.active : '',
|
|
824
|
+
locked ? styles$R.locked : '',
|
|
825
|
+
locked && active ? styles$R.lockedActive : '',
|
|
826
|
+
].filter(Boolean).join(' '), children: [jsx(Icon, { size: 16 }), tab.label, jsx("span", { className: styles$R.count, children: tab.count })] }, tab.key));
|
|
827
827
|
}) }));
|
|
828
828
|
};
|
|
829
829
|
|
|
830
|
-
var styles$
|
|
830
|
+
var styles$Q = {"navItem":"NavItem-module_navItem__4PpZU","disabled":"NavItem-module_disabled__uYqez","default":"NavItem-module_default__VB92P","active":"NavItem-module_active__3bcnW","pill":"NavItem-module_pill__pn5gl","icon":"NavItem-module_icon__j9VQ5","label":"NavItem-module_label__3S3KY","sm":"NavItem-module_sm__1oeZI","md":"NavItem-module_md__ySO90","lg":"NavItem-module_lg__OmaBw","collapsed":"NavItem-module_collapsed__ciZ6-","iconSm":"NavItem-module_iconSm__UvWnu","iconMd":"NavItem-module_iconMd__uAMlQ","iconLg":"NavItem-module_iconLg__PFPKD","badge":"NavItem-module_badge__oP9u2"};
|
|
831
831
|
|
|
832
832
|
const NavItem = ({ icon, label, active = false, collapsed = false, variant = 'default', size = 'md', badge, badgeVariant = 'default', onClick, disabled = false, href, external = false, className, 'aria-label': ariaLabel, }) => {
|
|
833
|
-
const content = (jsxs(Fragment, { children: [icon && jsx("span", { className: `${styles$
|
|
833
|
+
const content = (jsxs(Fragment, { children: [icon && jsx("span", { className: `${styles$Q.icon} ${styles$Q[`icon${size.charAt(0).toUpperCase()}${size.slice(1)}`]}`, "aria-hidden": "true", children: icon }), !collapsed && (jsx("span", { className: styles$Q.label, children: label })), badge !== undefined && !collapsed && (jsx(Badge, { variant: badgeVariant, className: styles$Q.badge, children: badge }))] }));
|
|
834
834
|
const classNames = [
|
|
835
|
-
styles$
|
|
836
|
-
styles$
|
|
837
|
-
styles$
|
|
838
|
-
active ? styles$
|
|
839
|
-
collapsed ? styles$
|
|
840
|
-
disabled ? styles$
|
|
835
|
+
styles$Q.navItem,
|
|
836
|
+
styles$Q[variant],
|
|
837
|
+
styles$Q[size],
|
|
838
|
+
active ? styles$Q.active : '',
|
|
839
|
+
collapsed ? styles$Q.collapsed : '',
|
|
840
|
+
disabled ? styles$Q.disabled : '',
|
|
841
841
|
className || '',
|
|
842
842
|
].filter(Boolean).join(' ');
|
|
843
843
|
const commonProps = {
|
|
@@ -852,7 +852,7 @@ const NavItem = ({ icon, label, active = false, collapsed = false, variant = 'de
|
|
|
852
852
|
return (jsx("button", { type: "button", onClick: disabled ? undefined : onClick, disabled: disabled, ...commonProps, children: content }));
|
|
853
853
|
};
|
|
854
854
|
|
|
855
|
-
var styles$
|
|
855
|
+
var styles$P = {"barContainer":"Progress-module_barContainer__e4v8v","barTrack":"Progress-module_barTrack__tJsPO","barFill":"Progress-module_barFill__RbcDy","barxs":"Progress-module_barxs__TLS4q","barsm":"Progress-module_barsm__BFAiw","barmd":"Progress-module_barmd__QDW-h","barlg":"Progress-module_barlg__C-Mzw","barLabel":"Progress-module_barLabel__4PFJ7","circleContainer":"Progress-module_circleContainer__zyOTa","circleSvg":"Progress-module_circleSvg__0Tt1Q","circleTrack":"Progress-module_circleTrack__p4VWf","circleFill":"Progress-module_circleFill__6fU2M","circleLabel":"Progress-module_circleLabel__vHLfU","primary":"Progress-module_primary__H2wpc","success":"Progress-module_success__rmmnE","warning":"Progress-module_warning__68ovy","error":"Progress-module_error__ZXkH0"};
|
|
856
856
|
|
|
857
857
|
const dimensions = {
|
|
858
858
|
xs: 32,
|
|
@@ -868,7 +868,7 @@ const strokeWidths = {
|
|
|
868
868
|
};
|
|
869
869
|
const ProgressBar = ({ value, max = 100, size = 'md', variant = 'primary', showLabel = false, className = '', }) => {
|
|
870
870
|
const percentage = Math.min(Math.max((value / max) * 100, 0), 100);
|
|
871
|
-
return (jsxs("div", { className: `${styles$
|
|
871
|
+
return (jsxs("div", { className: `${styles$P.barContainer} ${styles$P[`bar${size}`]} ${className}`, children: [jsx("div", { className: styles$P.barTrack, children: jsx("div", { className: `${styles$P.barFill} ${styles$P[variant]}`, style: { width: `${percentage}%` }, role: "progressbar", "aria-valuenow": value, "aria-valuemin": 0, "aria-valuemax": max }) }), showLabel && (jsxs("span", { className: styles$P.barLabel, children: [Math.round(percentage), "%"] }))] }));
|
|
872
872
|
};
|
|
873
873
|
const ProgressCircle = ({ value, max = 100, size = 'md', variant = 'primary', showLabel = false, className = '', }) => {
|
|
874
874
|
const percentage = Math.min(Math.max((value / max) * 100, 0), 100);
|
|
@@ -877,7 +877,7 @@ const ProgressCircle = ({ value, max = 100, size = 'md', variant = 'primary', sh
|
|
|
877
877
|
const radius = (dimension - strokeWidth) / 2;
|
|
878
878
|
const circumference = radius * 2 * Math.PI;
|
|
879
879
|
const strokeDashoffset = circumference - (percentage / 100) * circumference;
|
|
880
|
-
return (jsxs("div", { className: `${styles$
|
|
880
|
+
return (jsxs("div", { className: `${styles$P.circleContainer} ${className}`, style: { width: dimension, height: dimension }, children: [jsxs("svg", { width: dimension, height: dimension, className: styles$P.circleSvg, children: [jsx("circle", { className: styles$P.circleTrack, cx: dimension / 2, cy: dimension / 2, r: radius, strokeWidth: strokeWidth, fill: "transparent" }), jsx("circle", { className: `${styles$P.circleFill} ${styles$P[variant]}`, cx: dimension / 2, cy: dimension / 2, r: radius, strokeWidth: strokeWidth, fill: "transparent", strokeDasharray: circumference, strokeDashoffset: strokeDashoffset, strokeLinecap: "round", role: "progressbar", "aria-valuenow": value, "aria-valuemin": 0, "aria-valuemax": max })] }), showLabel && (jsxs("span", { className: styles$P.circleLabel, style: { fontSize: size === 'xs' ? '8px' : size === 'sm' ? '10px' : size === 'md' ? '12px' : '14px' }, children: [Math.round(percentage), "%"] }))] }));
|
|
881
881
|
};
|
|
882
882
|
// Combined export
|
|
883
883
|
const Progress = {
|
|
@@ -885,7 +885,7 @@ const Progress = {
|
|
|
885
885
|
Circle: ProgressCircle,
|
|
886
886
|
};
|
|
887
887
|
|
|
888
|
-
var styles$
|
|
888
|
+
var styles$O = {"toolbar":"RosterToolbar-module_toolbar__IHjs9","leftSection":"RosterToolbar-module_leftSection__baz7E","rightSection":"RosterToolbar-module_rightSection__R2b-D","dropdown":"RosterToolbar-module_dropdown__NKaWV","dropdownTrigger":"RosterToolbar-module_dropdownTrigger__nCoaZ","dropdownMenu":"RosterToolbar-module_dropdownMenu__7QuED","dropdownItem":"RosterToolbar-module_dropdownItem__mrsat","dropdownItemIcon":"RosterToolbar-module_dropdownItemIcon__gx5tx","lockButton":"RosterToolbar-module_lockButton__zw3s0","locked":"RosterToolbar-module_locked__DVnqB","saveButton":"RosterToolbar-module_saveButton__th1lq","spinner":"RosterToolbar-module_spinner__uWdPg"};
|
|
889
889
|
|
|
890
890
|
const ImportIcon = () => (jsxs("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: [jsx("path", { d: "M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4" }), jsx("polyline", { points: "17 8 12 3 7 8" }), jsx("line", { x1: "12", y1: "3", x2: "12", y2: "15" })] }));
|
|
891
891
|
const ExportIcon$1 = () => (jsxs("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: [jsx("path", { d: "M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4" }), jsx("polyline", { points: "7 10 12 15 17 10" }), jsx("line", { x1: "12", y1: "15", x2: "12", y2: "3" })] }));
|
|
@@ -893,23 +893,23 @@ const ChevronIcon$2 = () => (jsx("svg", { width: "12", height: "12", viewBox: "0
|
|
|
893
893
|
const LockIcon = () => (jsxs("svg", { width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: [jsx("rect", { x: "3", y: "11", width: "18", height: "11", rx: "2", ry: "2" }), jsx("path", { d: "M7 11V7a5 5 0 0 1 10 0v4" })] }));
|
|
894
894
|
const UnlockIcon = () => (jsxs("svg", { width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: [jsx("rect", { x: "3", y: "11", width: "18", height: "11", rx: "2", ry: "2" }), jsx("path", { d: "M7 11V7a5 5 0 0 1 9.9-1" })] }));
|
|
895
895
|
const SaveIcon = () => (jsxs("svg", { width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: [jsx("path", { d: "M19 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h11l5 5v11a2 2 0 0 1-2 2z" }), jsx("polyline", { points: "17 21 17 13 7 13 7 21" }), jsx("polyline", { points: "7 3 7 8 15 8" })] }));
|
|
896
|
-
const SpinnerIcon = () => (jsx("svg", { width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", className: styles$
|
|
896
|
+
const SpinnerIcon = () => (jsx("svg", { width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", className: styles$O.spinner, children: jsx("circle", { cx: "12", cy: "12", r: "10", strokeDasharray: "32", strokeDashoffset: "32" }) }));
|
|
897
897
|
const DropdownButton = ({ label, icon, options, }) => {
|
|
898
|
-
return (jsxs("div", { className: styles$
|
|
898
|
+
return (jsxs("div", { className: styles$O.dropdown, children: [jsxs("button", { type: "button", className: styles$O.dropdownTrigger, children: [icon, jsx("span", { children: label }), jsx(ChevronIcon$2, {})] }), jsx("div", { className: styles$O.dropdownMenu, children: options.map((option, i) => (jsxs("button", { type: "button", className: styles$O.dropdownItem, onClick: option.onClick, disabled: option.disabled, children: [option.icon && jsx("span", { className: styles$O.dropdownItemIcon, children: option.icon }), option.label] }, i))) })] }));
|
|
899
899
|
};
|
|
900
900
|
/**
|
|
901
901
|
* RosterToolbar - Toolbar for roster management with import/export/save actions
|
|
902
902
|
*/
|
|
903
903
|
const RosterToolbar = ({ importOptions, exportOptions, lockToggle, saveButton, additionalActions, searchField, className = '', }) => {
|
|
904
|
-
const toolbarClasses = [styles$
|
|
905
|
-
return (jsxs("div", { className: toolbarClasses, children: [jsxs("div", { className: styles$
|
|
906
|
-
styles$
|
|
907
|
-
lockToggle.isLocked ? styles$
|
|
908
|
-
].filter(Boolean).join(' '), onClick: () => lockToggle.onToggle(!lockToggle.isLocked), disabled: lockToggle.disabled, "aria-label": lockToggle.isLocked ? 'Unlock roster' : 'Lock roster', children: [lockToggle.isLocked ? jsx(LockIcon, {}) : jsx(UnlockIcon, {}), jsx("span", { children: lockToggle.isLocked ? 'Locked' : 'Unlocked' })] })), saveButton && (jsxs("button", { type: "button", className: styles$
|
|
904
|
+
const toolbarClasses = [styles$O.toolbar, className].filter(Boolean).join(' ');
|
|
905
|
+
return (jsxs("div", { className: toolbarClasses, children: [jsxs("div", { className: styles$O.leftSection, children: [searchField, additionalActions] }), jsxs("div", { className: styles$O.rightSection, children: [importOptions && importOptions.length > 0 && (jsx(DropdownButton, { label: "Import", icon: jsx(ImportIcon, {}), options: importOptions })), exportOptions && exportOptions.length > 0 && (jsx(DropdownButton, { label: "Export", icon: jsx(ExportIcon$1, {}), options: exportOptions })), lockToggle && (jsxs("button", { type: "button", className: [
|
|
906
|
+
styles$O.lockButton,
|
|
907
|
+
lockToggle.isLocked ? styles$O.locked : '',
|
|
908
|
+
].filter(Boolean).join(' '), onClick: () => lockToggle.onToggle(!lockToggle.isLocked), disabled: lockToggle.disabled, "aria-label": lockToggle.isLocked ? 'Unlock roster' : 'Lock roster', children: [lockToggle.isLocked ? jsx(LockIcon, {}) : jsx(UnlockIcon, {}), jsx("span", { children: lockToggle.isLocked ? 'Locked' : 'Unlocked' })] })), saveButton && (jsxs("button", { type: "button", className: styles$O.saveButton, onClick: saveButton.onClick, disabled: saveButton.disabled || saveButton.loading, children: [saveButton.loading ? jsx(SpinnerIcon, {}) : jsx(SaveIcon, {}), jsx("span", { children: saveButton.label || 'Save' })] }))] })] }));
|
|
909
909
|
};
|
|
910
910
|
RosterToolbar.displayName = 'RosterToolbar';
|
|
911
911
|
|
|
912
|
-
var styles$
|
|
912
|
+
var styles$N = {"searchField":"SearchField-module_searchField__c7gUE","inputWrapper":"SearchField-module_inputWrapper__SUzHv","searchIcon":"SearchField-module_searchIcon__MOZ2m","input":"SearchField-module_input__abJcl","clearButton":"SearchField-module_clearButton__RMIg2","sm":"SearchField-module_sm__-sayT","lg":"SearchField-module_lg__QKacI"};
|
|
913
913
|
|
|
914
914
|
const SearchField = forwardRef(({ placeholder = 'Search...', value, defaultValue = '', onChange, onSearch, onClear, size = 'md', disabled = false, showClear = true, showButton = true, className, id, 'aria-label': ariaLabel = 'Search', ...props }, ref) => {
|
|
915
915
|
const [internalValue, setInternalValue] = useState(defaultValue);
|
|
@@ -937,25 +937,25 @@ const SearchField = forwardRef(({ placeholder = 'Search...', value, defaultValue
|
|
|
937
937
|
onSearch?.(currentValue);
|
|
938
938
|
}
|
|
939
939
|
};
|
|
940
|
-
return (jsxs("form", { className: `${styles$
|
|
940
|
+
return (jsxs("form", { className: `${styles$N.searchField} ${styles$N[size]} ${className || ''}`, onSubmit: handleSubmit, role: "search", children: [jsxs("div", { className: styles$N.inputWrapper, children: [jsx(SearchIcon$1, { className: styles$N.searchIcon, "aria-hidden": "true" }), jsx(Input, { ref: ref, id: id, type: "search", placeholder: placeholder, value: currentValue, onChange: handleChange, onKeyDown: handleKeyDown, disabled: disabled, className: styles$N.input, "aria-label": ariaLabel, ...props }), showClear && currentValue && (jsx("button", { type: "button", className: styles$N.clearButton, onClick: handleClear, disabled: disabled, "aria-label": "Clear search", children: jsx(CloseIcon, { size: 16 }) }))] }), showButton && (jsx(Button, { type: "submit", variant: "primary", size: size, disabled: disabled, children: "Search" }))] }));
|
|
941
941
|
});
|
|
942
942
|
SearchField.displayName = 'SearchField';
|
|
943
943
|
|
|
944
|
-
var styles$
|
|
944
|
+
var styles$M = {"form":"SchoolContactForm-module_form__-Mx7k","portalLabel":"SchoolContactForm-module_portalLabel__GAeV6","newContactLabel":"SchoolContactForm-module_newContactLabel__7S3Vw","divider":"SchoolContactForm-module_divider__ZSx-R","nameFields":"SchoolContactForm-module_nameFields__Fcjl8","phoneFields":"SchoolContactForm-module_phoneFields__-zRPe"};
|
|
945
945
|
|
|
946
946
|
/**
|
|
947
947
|
* Layout for Hub's school-contact editor. Field controls stay injectable so
|
|
948
948
|
* consuming applications retain their form state, validation, and masking.
|
|
949
949
|
*/
|
|
950
|
-
const SchoolContactForm = ({ mode, createFromPortalUser, firstNameField, middleInitialField, lastNameField, businessPhoneField, cellPhoneField, emailField, className = '', }) => (jsxs("div", { className: [styles$
|
|
950
|
+
const SchoolContactForm = ({ mode, createFromPortalUser, firstNameField, middleInitialField, lastNameField, businessPhoneField, cellPhoneField, emailField, className = '', }) => (jsxs("div", { className: [styles$M.form, className].filter(Boolean).join(' '), children: [mode === 'Add' && (jsxs(Fragment, { children: [jsxs("div", { children: [jsx("label", { className: styles$M.portalLabel, children: "Create From Portal User" }), createFromPortalUser] }), jsx("div", { className: styles$M.divider, children: jsx("strong", { children: "OR" }) }), jsx("p", { className: styles$M.newContactLabel, children: "Create New Contact Without Portal Access" })] })), jsxs("div", { className: styles$M.nameFields, children: [firstNameField, middleInitialField, lastNameField] }), jsxs("div", { className: styles$M.phoneFields, children: [businessPhoneField, cellPhoneField] }), jsx("div", { children: emailField })] }));
|
|
951
951
|
|
|
952
|
-
var styles$
|
|
952
|
+
var styles$L = {"segment":"Segment-module_segment__UF-SG","fullWidth":"Segment-module_fullWidth__Hi19i","option":"Segment-module_option__UJUhj","disabled":"Segment-module_disabled__CSxuQ","selected":"Segment-module_selected__gRnVj","sm":"Segment-module_sm__h8S7Z","md":"Segment-module_md__4uTae","lg":"Segment-module_lg__zL0Hv","icon":"Segment-module_icon__ZHRr6"};
|
|
953
953
|
|
|
954
954
|
const Segment = ({ options, value, onChange, size = 'md', fullWidth = false, className = '', 'aria-label': ariaLabel, }) => {
|
|
955
|
-
return (jsx("div", { className: `${styles$
|
|
955
|
+
return (jsx("div", { className: `${styles$L.segment} ${styles$L[size]} ${fullWidth ? styles$L.fullWidth : ''} ${className}`, role: "radiogroup", "aria-label": ariaLabel, children: options.map((option) => (jsxs("button", { type: "button", className: `${styles$L.option} ${value === option.value ? styles$L.selected : ''} ${option.disabled ? styles$L.disabled : ''}`, onClick: () => !option.disabled && onChange(option.value), disabled: option.disabled, role: "radio", "aria-checked": value === option.value, children: [option.icon && jsx("span", { className: styles$L.icon, children: option.icon }), option.label] }, option.value))) }));
|
|
956
956
|
};
|
|
957
957
|
|
|
958
|
-
var styles$
|
|
958
|
+
var styles$K = {"container":"SelectFilter-module_container__tCC9y","trigger":"SelectFilter-module_trigger__5WbMf","open":"SelectFilter-module_open__oo-Y6","disabled":"SelectFilter-module_disabled__JUdi3","triggerText":"SelectFilter-module_triggerText__LM07K","placeholder":"SelectFilter-module_placeholder__J0xyo","chevron":"SelectFilter-module_chevron__x-Pnr","dropdown":"SelectFilter-module_dropdown__52FPP","tabs":"SelectFilter-module_tabs__wp6on","tab":"SelectFilter-module_tab__JpnWo","activeTab":"SelectFilter-module_activeTab__ShP7x","actions":"SelectFilter-module_actions__phfFl","actionBtn":"SelectFilter-module_actionBtn__ppB--","options":"SelectFilter-module_options__p1iCX","option":"SelectFilter-module_option__0vwfy","selected":"SelectFilter-module_selected__2vxyT","checkbox":"SelectFilter-module_checkbox__qTUjy","optionLabel":"SelectFilter-module_optionLabel__L4CMA","footer":"SelectFilter-module_footer__aq4JP","applyBtn":"SelectFilter-module_applyBtn__RFKei"};
|
|
959
959
|
|
|
960
960
|
const ChevronIcon$1 = () => (jsx("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: jsx("polyline", { points: "6 9 12 15 18 9" }) }));
|
|
961
961
|
const CheckIcon = () => (jsx("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: jsx("polyline", { points: "20 6 9 17 4 12" }) }));
|
|
@@ -1028,11 +1028,11 @@ const SelectFilter = ({ label, options = [], groupedOptions = {}, value = [], on
|
|
|
1028
1028
|
}
|
|
1029
1029
|
return `${selected.length} selected`;
|
|
1030
1030
|
};
|
|
1031
|
-
return (jsxs("div", { ref: dropdownRef, className: `${styles$
|
|
1031
|
+
return (jsxs("div", { ref: dropdownRef, className: `${styles$K.container} ${className}`, children: [jsxs("button", { type: "button", className: `${styles$K.trigger} ${disabled ? styles$K.disabled : ''} ${isOpen ? styles$K.open : ''}`, onClick: () => !disabled && setIsOpen(!isOpen), children: [jsx("span", { className: `${styles$K.triggerText} ${selectedValues.length === 0 ? styles$K.placeholder : ''}`, children: getDisplayText() }), jsx("span", { className: styles$K.chevron, children: jsx(ChevronIcon$1, {}) })] }), isOpen && (jsxs("div", { className: styles$K.dropdown, style: { width }, children: [grouped && tabs.length > 0 && (jsx("div", { className: styles$K.tabs, children: tabs.map(tab => (jsx("button", { type: "button", className: `${styles$K.tab} ${activeTab === tab ? styles$K.activeTab : ''}`, onClick: () => setActiveTab(tab), children: tab.charAt(0).toUpperCase() + tab.slice(1) }, tab))) })), multiselect && (jsxs("div", { className: styles$K.actions, children: [jsx("button", { type: "button", className: styles$K.actionBtn, onClick: handleSelectAll, children: "Select All" }), jsx("button", { type: "button", className: styles$K.actionBtn, onClick: handleClear, children: "Clear" })] })), jsx("div", { className: styles$K.options, children: currentOptions.map(option => (jsxs("div", { className: `${styles$K.option} ${selectedValues.includes(option.value) ? styles$K.selected : ''}`, onClick: () => handleSelect(option.value), children: [multiselect && (jsx("span", { className: styles$K.checkbox, children: selectedValues.includes(option.value) && jsx(CheckIcon, {}) })), jsx("span", { className: styles$K.optionLabel, children: option.label })] }, option.value))) }), multiselect && (jsx("div", { className: styles$K.footer, children: jsx("button", { type: "button", className: styles$K.applyBtn, onClick: () => setIsOpen(false), children: "Apply" }) }))] }))] }));
|
|
1032
1032
|
};
|
|
1033
1033
|
SelectFilter.displayName = 'SelectFilter';
|
|
1034
1034
|
|
|
1035
|
-
var styles$
|
|
1035
|
+
var styles$J = {"list":"ServiceToggle-module_list__bBts8","item":"ServiceToggle-module_item__4wEbQ","labelContainer":"ServiceToggle-module_labelContainer__oz-I1","clickable":"ServiceToggle-module_clickable__yzQxe","icon":"ServiceToggle-module_icon__8IdST","label":"ServiceToggle-module_label__J98Ve"};
|
|
1036
1036
|
|
|
1037
1037
|
/**
|
|
1038
1038
|
* ServiceToggle component for a single service item.
|
|
@@ -1045,19 +1045,19 @@ const ServiceToggle = ({ label, icon, hasToggle = true, enabled = false, onToggl
|
|
|
1045
1045
|
onClick();
|
|
1046
1046
|
}
|
|
1047
1047
|
};
|
|
1048
|
-
return (jsxs("div", { className: styles$
|
|
1048
|
+
return (jsxs("div", { className: styles$J.item, children: [jsxs("div", { className: `${styles$J.labelContainer} ${isClickable ? styles$J.clickable : ''}`, onClick: handleClick, children: [icon && jsx("span", { className: styles$J.icon, children: icon }), jsx("span", { className: styles$J.label, children: label })] }), hasToggle && (jsx(Toggle, { "aria-label": label, checked: enabled, onChange: (checked) => onToggle?.(checked), disabled: disabled, size: "sm" }))] }));
|
|
1049
1049
|
};
|
|
1050
1050
|
/**
|
|
1051
1051
|
* ServiceToggleList component for displaying a list of services with toggles.
|
|
1052
1052
|
* Used in travel request forms for service selection (Air, Hotel, Ground, etc.)
|
|
1053
1053
|
*/
|
|
1054
1054
|
const ServiceToggleList = ({ services, enabledServices = {}, onToggle, onClick, className, }) => {
|
|
1055
|
-
return (jsx("div", { className: `${styles$
|
|
1055
|
+
return (jsx("div", { className: `${styles$J.list} ${className || ''}`, children: services.map((service) => (jsx(ServiceToggle, { serviceKey: service.key, label: service.label, icon: service.icon, hasToggle: service.hasToggle, enabled: enabledServices[service.key] ?? false, onToggle: (enabled) => onToggle?.(service.key, enabled), onClick: () => onClick?.(service.key) }, service.key))) }));
|
|
1056
1056
|
};
|
|
1057
1057
|
ServiceToggle.displayName = 'ServiceToggle';
|
|
1058
1058
|
ServiceToggleList.displayName = 'ServiceToggleList';
|
|
1059
1059
|
|
|
1060
|
-
var styles$
|
|
1060
|
+
var styles$I = {"toggle":"SupplierTypeToggle-module_toggle__x4pTJ","active":"SupplierTypeToggle-module_active__8BGSe"};
|
|
1061
1061
|
|
|
1062
1062
|
const SUPPLIER_TYPE_OPTIONS = [
|
|
1063
1063
|
{ value: 'A', label: 'Air' },
|
|
@@ -1078,10 +1078,10 @@ const SupplierTypeToggle = ({ value, defaultValue = '', onChange, disabled = fal
|
|
|
1078
1078
|
setInternalValue(nextValue);
|
|
1079
1079
|
onChange?.(nextValue);
|
|
1080
1080
|
};
|
|
1081
|
-
return (jsx("div", { className: [styles$
|
|
1081
|
+
return (jsx("div", { className: [styles$I.toggle, className].filter(Boolean).join(' '), role: "group", "aria-label": "Supplier type", children: OPTIONS.map((option) => (jsx("button", { type: "button", disabled: disabled, "aria-pressed": activeValue === option.value, className: activeValue === option.value ? styles$I.active : '', onClick: () => handleSelect(option.value), children: option.label }, option.value || 'all'))) }));
|
|
1082
1082
|
};
|
|
1083
1083
|
|
|
1084
|
-
var styles$
|
|
1084
|
+
var styles$H = {"header":"TeamHeader-module_header__3Zx1c","empty":"TeamHeader-module_empty__fKrFE","left":"TeamHeader-module_left__yqug2","backButton":"TeamHeader-module_backButton__MqElX","titles":"TeamHeader-module_titles__m3Ne9","pretitle":"TeamHeader-module_pretitle__rZUD6","title":"TeamHeader-module_title__i3dmZ","actions":"TeamHeader-module_actions__ft1DN","subMenu":"TeamHeader-module_subMenu__oL-3Q","activeTab":"TeamHeader-module_activeTab__AUzdq"};
|
|
1085
1085
|
|
|
1086
1086
|
const BackIcon = () => (jsxs("svg", { width: "20", height: "20", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: [jsx("line", { x1: "19", y1: "12", x2: "5", y2: "12" }), jsx("polyline", { points: "12 19 5 12 12 5" })] }));
|
|
1087
1087
|
/**
|
|
@@ -1092,8 +1092,8 @@ const TeamHeader = ({ title: suppliedTitle, teamCode, teamName, pretitle = 'Team
|
|
|
1092
1092
|
? `${teamCode} - ${teamName}`
|
|
1093
1093
|
: teamName || teamCode || '');
|
|
1094
1094
|
const headerClasses = [
|
|
1095
|
-
styles$
|
|
1096
|
-
!title ? styles$
|
|
1095
|
+
styles$H.header,
|
|
1096
|
+
!title ? styles$H.empty : '',
|
|
1097
1097
|
className,
|
|
1098
1098
|
].filter(Boolean).join(' ');
|
|
1099
1099
|
const handleBack = () => {
|
|
@@ -1105,7 +1105,7 @@ const TeamHeader = ({ title: suppliedTitle, teamCode, teamName, pretitle = 'Team
|
|
|
1105
1105
|
window.location.href = backHref;
|
|
1106
1106
|
}
|
|
1107
1107
|
};
|
|
1108
|
-
return (jsxs("div", { className: headerClasses, "data-test": "team-header", children: [jsxs("div", { className: styles$
|
|
1108
|
+
return (jsxs("div", { className: headerClasses, "data-test": "team-header", children: [jsxs("div", { className: styles$H.left, children: [(backHref || onBack) && (jsx("button", { type: "button", className: styles$H.backButton, onClick: handleBack, "aria-label": "Go back", "data-test": "team-header-back", children: jsx(BackIcon, {}) })), jsxs("div", { className: styles$H.titles, children: [pretitle && jsx("span", { className: styles$H.pretitle, children: pretitle }), jsxs("h1", { className: styles$H.title, children: [title, "\u00A0"] })] })] }), actions && (jsx("div", { className: styles$H.actions, children: actions }))] }));
|
|
1109
1109
|
};
|
|
1110
1110
|
const DEFAULT_TABS$1 = [
|
|
1111
1111
|
{ id: 'profile', label: 'Profile' },
|
|
@@ -1114,11 +1114,11 @@ const DEFAULT_TABS$1 = [
|
|
|
1114
1114
|
{ id: 'user-access', label: 'User Access' },
|
|
1115
1115
|
];
|
|
1116
1116
|
/** Router-agnostic counterpart of Hub's team-management submenu. */
|
|
1117
|
-
const TeamSubMenu = ({ tabs = DEFAULT_TABS$1, activeTab, onTabChange, className = '' }) => (jsx("nav", { className: [styles$
|
|
1117
|
+
const TeamSubMenu = ({ tabs = DEFAULT_TABS$1, activeTab, onTabChange, className = '' }) => (jsx("nav", { className: [styles$H.subMenu, className].filter(Boolean).join(' '), "aria-label": "Team management sections", "data-test": "team-management-tabs", children: tabs.map((tab) => (jsx("button", { type: "button", className: activeTab === tab.id ? styles$H.activeTab : '', "aria-current": activeTab === tab.id ? 'page' : undefined, "data-test": `team-management-tab-${tab.id}`, onClick: () => onTabChange?.(tab.id), children: tab.label }, tab.id))) }));
|
|
1118
1118
|
TeamHeader.displayName = 'TeamHeader';
|
|
1119
1119
|
TeamSubMenu.displayName = 'TeamSubMenu';
|
|
1120
1120
|
|
|
1121
|
-
var styles$
|
|
1121
|
+
var styles$G = {"segment":"TripSegment-module_segment__jX-Nq","light":"TripSegment-module_light__hHSb3","dark":"TripSegment-module_dark__3Fuo7","empty":"TripSegment-module_empty__vmzg0","item":"TripSegment-module_item__S-RC1","itemHeader":"TripSegment-module_itemHeader__wFWMo","itemType":"TripSegment-module_itemType__NsDLe","itemName":"TripSegment-module_itemName__ysYsC","route":"TripSegment-module_route__Shyz0","location":"TripSegment-module_location__8VCMH","details":"TripSegment-module_details__4U4Km","dates":"TripSegment-module_dates__Wn4-k"};
|
|
1122
1122
|
|
|
1123
1123
|
const PlaneIcon$2 = () => (jsx("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: jsx("path", { d: "M21 16v-2l-8-5V3.5a1.5 1.5 0 0 0-3 0V9l-8 5v2l8-2.5V19l-2 1.5V22l3.5-1 3.5 1v-1.5L13 19v-5.5l8 2.5Z" }) }));
|
|
1124
1124
|
const BusIcon$1 = () => (jsxs("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: [jsx("rect", { x: "4", y: "4", width: "16", height: "14", rx: "2" }), jsx("path", { d: "M8 6v6" }), jsx("path", { d: "M16 6v6" }), jsx("circle", { cx: "8", cy: "16", r: "1" }), jsx("circle", { cx: "16", cy: "16", r: "1" })] }));
|
|
@@ -1128,41 +1128,41 @@ const ArrowIcon = () => (jsxs("svg", { width: "12", height: "12", viewBox: "0 0
|
|
|
1128
1128
|
* Base TripSegment component wrapper
|
|
1129
1129
|
*/
|
|
1130
1130
|
const TripSegment = ({ type: _type, variant = 'light', className = '', children, }) => {
|
|
1131
|
-
return (jsx("div", { className: `${styles$
|
|
1131
|
+
return (jsx("div", { className: `${styles$G.segment} ${styles$G[variant]} ${className}`, children: children }));
|
|
1132
1132
|
};
|
|
1133
1133
|
/**
|
|
1134
1134
|
* AirSegment component for displaying flight information
|
|
1135
1135
|
*/
|
|
1136
1136
|
const AirSegment = ({ flights, variant = 'light', className = '', }) => {
|
|
1137
1137
|
if (!flights || flights.length === 0) {
|
|
1138
|
-
return (jsx(TripSegment, { type: "air", variant: variant, className: className, children: jsx("span", { className: styles$
|
|
1138
|
+
return (jsx(TripSegment, { type: "air", variant: variant, className: className, children: jsx("span", { className: styles$G.empty, children: "No flights" }) }));
|
|
1139
1139
|
}
|
|
1140
|
-
return (jsx(TripSegment, { type: "air", variant: variant, className: className, children: flights.map((flight, i) => (jsxs("div", { className: styles$
|
|
1140
|
+
return (jsx(TripSegment, { type: "air", variant: variant, className: className, children: flights.map((flight, i) => (jsxs("div", { className: styles$G.item, children: [jsxs("div", { className: styles$G.itemHeader, children: [jsx(PlaneIcon$2, {}), jsx("span", { className: styles$G.itemType, children: flight.type === 'charter' ? 'Charter' : 'Commercial' })] }), jsxs("div", { className: styles$G.route, children: [jsx("span", { className: styles$G.location, children: flight.departure }), jsx(ArrowIcon, {}), jsx("span", { className: styles$G.location, children: flight.arrival })] }), jsxs("div", { className: styles$G.details, children: [jsx("span", { children: flight.departureDate }), flight.departureTime && jsx("span", { children: flight.departureTime })] }), flight.airline && (jsxs("div", { className: styles$G.details, children: [jsx("span", { children: flight.airline }), flight.flightNumber && jsxs("span", { children: ["#", flight.flightNumber] })] }))] }, i))) }));
|
|
1141
1141
|
};
|
|
1142
1142
|
/**
|
|
1143
1143
|
* GroundSegment component for displaying ground transportation
|
|
1144
1144
|
*/
|
|
1145
1145
|
const GroundSegment = ({ segments, variant = 'light', className = '', }) => {
|
|
1146
1146
|
if (!segments || segments.length === 0) {
|
|
1147
|
-
return (jsx(TripSegment, { type: "ground", variant: variant, className: className, children: jsx("span", { className: styles$
|
|
1147
|
+
return (jsx(TripSegment, { type: "ground", variant: variant, className: className, children: jsx("span", { className: styles$G.empty, children: "No ground transportation" }) }));
|
|
1148
1148
|
}
|
|
1149
|
-
return (jsx(TripSegment, { type: "ground", variant: variant, className: className, children: segments.map((segment, i) => (jsxs("div", { className: styles$
|
|
1149
|
+
return (jsx(TripSegment, { type: "ground", variant: variant, className: className, children: segments.map((segment, i) => (jsxs("div", { className: styles$G.item, children: [jsxs("div", { className: styles$G.itemHeader, children: [jsx(BusIcon$1, {}), jsx("span", { className: styles$G.itemType, children: segment.type.charAt(0).toUpperCase() + segment.type.slice(1) })] }), jsxs("div", { className: styles$G.route, children: [jsx("span", { className: styles$G.location, children: segment.pickupLocation }), jsx(ArrowIcon, {}), jsx("span", { className: styles$G.location, children: segment.dropoffLocation })] }), jsxs("div", { className: styles$G.details, children: [jsx("span", { children: segment.pickupDate }), segment.pickupTime && jsx("span", { children: segment.pickupTime })] }), segment.company && (jsxs("div", { className: styles$G.details, children: [jsx("span", { children: segment.company }), segment.vehicleCount && jsxs("span", { children: [segment.vehicleCount, " vehicles"] })] }))] }, i))) }));
|
|
1150
1150
|
};
|
|
1151
1151
|
/**
|
|
1152
1152
|
* HotelSegment component for displaying hotel information
|
|
1153
1153
|
*/
|
|
1154
1154
|
const HotelSegment = ({ hotels, variant = 'light', className = '', }) => {
|
|
1155
1155
|
if (!hotels || hotels.length === 0) {
|
|
1156
|
-
return (jsx(TripSegment, { type: "hotel", variant: variant, className: className, children: jsx("span", { className: styles$
|
|
1156
|
+
return (jsx(TripSegment, { type: "hotel", variant: variant, className: className, children: jsx("span", { className: styles$G.empty, children: "No hotels" }) }));
|
|
1157
1157
|
}
|
|
1158
|
-
return (jsx(TripSegment, { type: "hotel", variant: variant, className: className, children: hotels.map((hotel, i) => (jsxs("div", { className: styles$
|
|
1158
|
+
return (jsx(TripSegment, { type: "hotel", variant: variant, className: className, children: hotels.map((hotel, i) => (jsxs("div", { className: styles$G.item, children: [jsxs("div", { className: styles$G.itemHeader, children: [jsx(HotelIcon$2, {}), jsx("span", { className: styles$G.itemName, children: hotel.name })] }), hotel.city && (jsx("div", { className: styles$G.details, children: jsx("span", { children: hotel.city }) })), jsxs("div", { className: styles$G.dates, children: [jsx("span", { children: hotel.checkIn }), jsx("span", { children: "\u2013" }), jsx("span", { children: hotel.checkOut })] }), hotel.roomCount && (jsx("div", { className: styles$G.details, children: jsxs("span", { children: [hotel.roomCount, " rooms"] }) }))] }, i))) }));
|
|
1159
1159
|
};
|
|
1160
1160
|
TripSegment.displayName = 'TripSegment';
|
|
1161
1161
|
AirSegment.displayName = 'AirSegment';
|
|
1162
1162
|
GroundSegment.displayName = 'GroundSegment';
|
|
1163
1163
|
HotelSegment.displayName = 'HotelSegment';
|
|
1164
1164
|
|
|
1165
|
-
var styles$
|
|
1165
|
+
var styles$F = {"sidenav":"Sidenav-module_sidenav__9DKVg","expanded":"Sidenav-module_expanded__TfkMs","collapsed":"Sidenav-module_collapsed__xyLkg","toggle":"Sidenav-module_toggle__JCoZu","logoContainer":"Sidenav-module_logoContainer__lLl0-","nav":"Sidenav-module_nav__ZwGrU","navItem":"Sidenav-module_navItem__HhFpj","active":"Sidenav-module_active__-oHUp","icon":"Sidenav-module_icon__7XJWf","label":"Sidenav-module_label__DJDBw","footer":"Sidenav-module_footer__EgrDk"};
|
|
1166
1166
|
|
|
1167
1167
|
/**
|
|
1168
1168
|
* Sidenav component for main navigation.
|
|
@@ -1171,8 +1171,8 @@ var styles$D = {"sidenav":"Sidenav-module_sidenav__9DKVg","expanded":"Sidenav-mo
|
|
|
1171
1171
|
const Sidenav = ({ logo, logoCollapsed, items, activeKey, onItemClick, defaultExpanded = true, footer, className = '', ...props }) => {
|
|
1172
1172
|
const [expanded, setExpanded] = useState(defaultExpanded);
|
|
1173
1173
|
const classNames = [
|
|
1174
|
-
styles$
|
|
1175
|
-
expanded ? styles$
|
|
1174
|
+
styles$F.sidenav,
|
|
1175
|
+
expanded ? styles$F.expanded : styles$F.collapsed,
|
|
1176
1176
|
className,
|
|
1177
1177
|
]
|
|
1178
1178
|
.filter(Boolean)
|
|
@@ -1185,20 +1185,20 @@ const Sidenav = ({ logo, logoCollapsed, items, activeKey, onItemClick, defaultEx
|
|
|
1185
1185
|
onItemClick(item.key);
|
|
1186
1186
|
}
|
|
1187
1187
|
};
|
|
1188
|
-
return (jsxs("aside", { className: classNames, ...props, children: [jsx("button", { className: styles$
|
|
1188
|
+
return (jsxs("aside", { className: classNames, ...props, children: [jsx("button", { className: styles$F.toggle, onClick: () => setExpanded(!expanded), "aria-label": expanded ? 'Collapse sidebar' : 'Expand sidebar', children: expanded ? (jsx(ChevronLeftIcon, { size: 16 })) : (jsx(ChevronRightIcon$1, { size: 16 })) }), jsx("div", { className: styles$F.logoContainer, children: expanded ? logo : logoCollapsed || logo }), jsx("nav", { className: styles$F.nav, children: items.map((item) => {
|
|
1189
1189
|
const isActive = item.key === activeKey;
|
|
1190
1190
|
const itemClasses = [
|
|
1191
|
-
styles$
|
|
1192
|
-
isActive ? styles$
|
|
1191
|
+
styles$F.navItem,
|
|
1192
|
+
isActive ? styles$F.active : '',
|
|
1193
1193
|
]
|
|
1194
1194
|
.filter(Boolean)
|
|
1195
1195
|
.join(' ');
|
|
1196
|
-
return (jsxs("button", { className: itemClasses, onClick: () => handleItemClick(item), "aria-current": isActive ? 'page' : undefined, title: !expanded ? item.label : undefined, children: [jsx("span", { className: styles$
|
|
1197
|
-
}) }), footer && jsx("div", { className: styles$
|
|
1196
|
+
return (jsxs("button", { className: itemClasses, onClick: () => handleItemClick(item), "aria-current": isActive ? 'page' : undefined, title: !expanded ? item.label : undefined, children: [jsx("span", { className: styles$F.icon, children: item.icon }), expanded && jsx("span", { className: styles$F.label, children: item.label })] }, item.key));
|
|
1197
|
+
}) }), footer && jsx("div", { className: styles$F.footer, children: footer })] }));
|
|
1198
1198
|
};
|
|
1199
1199
|
Sidenav.displayName = 'Sidenav';
|
|
1200
1200
|
|
|
1201
|
-
var styles$
|
|
1201
|
+
var styles$E = {"topbar":"Topbar-module_topbar__U9CDj","left":"Topbar-module_left__m4aap","accountWrapper":"Topbar-module_accountWrapper__5mjDZ","accountSelector":"Topbar-module_accountSelector__iqI--","open":"Topbar-module_open__2Xsp1","accountCode":"Topbar-module_accountCode__KMKWm","accountName":"Topbar-module_accountName__XZYjB","chevron":"Topbar-module_chevron__OSXcD","chevronOpen":"Topbar-module_chevronOpen__jVvEl","dropdown":"Topbar-module_dropdown__fA5Gw","dropdownSearch":"Topbar-module_dropdownSearch__9zqy3","searchIcon":"Topbar-module_searchIcon__sHGnK","searchInput":"Topbar-module_searchInput__1TSc3","dropdownList":"Topbar-module_dropdownList__P4q9b","dropdownItem":"Topbar-module_dropdownItem__w-eHf","selected":"Topbar-module_selected__MylKY","dropdownItemCode":"Topbar-module_dropdownItemCode__cUAn6","dropdownItemName":"Topbar-module_dropdownItemName__MYw3k","noResults":"Topbar-module_noResults__PkNfT","actions":"Topbar-module_actions__KtaiZ"};
|
|
1202
1202
|
|
|
1203
1203
|
/**
|
|
1204
1204
|
* Topbar component for the main header.
|
|
@@ -1209,7 +1209,7 @@ const Topbar = ({ account, accounts, onAccountSelect, onAccountClick, actions, l
|
|
|
1209
1209
|
const [searchQuery, setSearchQuery] = useState('');
|
|
1210
1210
|
const dropdownRef = useRef(null);
|
|
1211
1211
|
const searchInputRef = useRef(null);
|
|
1212
|
-
const classNames = [styles$
|
|
1212
|
+
const classNames = [styles$E.topbar, className].filter(Boolean).join(' ');
|
|
1213
1213
|
// Close dropdown on outside click
|
|
1214
1214
|
useEffect(() => {
|
|
1215
1215
|
if (!isOpen)
|
|
@@ -1258,27 +1258,27 @@ const Topbar = ({ account, accounts, onAccountSelect, onAccountClick, actions, l
|
|
|
1258
1258
|
const filteredAccounts = accounts?.filter(acc => acc.name.toLowerCase().includes(searchQuery.toLowerCase()) ||
|
|
1259
1259
|
acc.code.toLowerCase().includes(searchQuery.toLowerCase())) || [];
|
|
1260
1260
|
const hasDropdown = accounts && accounts.length > 0;
|
|
1261
|
-
return (jsxs("header", { className: classNames, ...props, children: [jsxs("div", { className: styles$
|
|
1261
|
+
return (jsxs("header", { className: classNames, ...props, children: [jsxs("div", { className: styles$E.left, children: [leftContent, account && (jsxs("div", { className: styles$E.accountWrapper, ref: dropdownRef, children: [jsxs("button", { className: `${styles$E.accountSelector} ${isOpen ? styles$E.open : ''}`, onClick: handleToggle, "aria-expanded": isOpen, "aria-haspopup": hasDropdown ? 'listbox' : undefined, children: [jsx("span", { className: styles$E.accountCode, children: account.code }), jsx("span", { className: styles$E.accountName, children: account.name }), hasDropdown && (jsx(ChevronDownIcon$1, { size: 16, className: `${styles$E.chevron} ${isOpen ? styles$E.chevronOpen : ''}` }))] }), isOpen && hasDropdown && (jsxs("div", { className: styles$E.dropdown, role: "listbox", children: [jsxs("div", { className: styles$E.dropdownSearch, children: [jsxs("svg", { className: styles$E.searchIcon, width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: [jsx("circle", { cx: "11", cy: "11", r: "8" }), jsx("line", { x1: "21", y1: "21", x2: "16.65", y2: "16.65" })] }), jsx("input", { ref: searchInputRef, type: "text", value: searchQuery, onChange: (e) => setSearchQuery(e.target.value), placeholder: "Search accounts...", className: styles$E.searchInput })] }), jsx("div", { className: styles$E.dropdownList, children: filteredAccounts.length > 0 ? (filteredAccounts.map((acc) => (jsxs("button", { className: `${styles$E.dropdownItem} ${acc.code === account.code ? styles$E.selected : ''}`, onClick: () => handleSelectAccount(acc), role: "option", "aria-selected": acc.code === account.code, children: [jsx("span", { className: styles$E.dropdownItemCode, children: acc.code }), jsx("span", { className: styles$E.dropdownItemName, children: acc.name })] }, acc.code)))) : (jsx("div", { className: styles$E.noResults, children: "No accounts found" })) })] }))] }))] }), actions && jsx("div", { className: styles$E.actions, children: actions })] }));
|
|
1262
1262
|
};
|
|
1263
1263
|
Topbar.displayName = 'Topbar';
|
|
1264
1264
|
|
|
1265
|
-
var styles$
|
|
1265
|
+
var styles$D = {"appLayout":"AppLayout-module_appLayout__NFbZk","mainArea":"AppLayout-module_mainArea__t-6oq","content":"AppLayout-module_content__5kV7S"};
|
|
1266
1266
|
|
|
1267
1267
|
const AppLayout = ({ navItems = [], activeNavKey, logo, collapsedLogo, account, defaultExpanded = true, onNavItemClick, onAccountClick, children, navFooter, topbarActions, className, }) => {
|
|
1268
|
-
return (jsxs("div", { className: `${styles$
|
|
1268
|
+
return (jsxs("div", { className: `${styles$D.appLayout} ${className || ''}`, children: [jsx(Sidenav, { items: navItems, activeKey: activeNavKey, defaultExpanded: defaultExpanded, onItemClick: onNavItemClick, logo: logo, logoCollapsed: collapsedLogo, footer: navFooter }), jsxs("div", { className: styles$D.mainArea, children: [jsx(Topbar, { account: account, onAccountClick: onAccountClick, actions: topbarActions }), jsx("main", { className: styles$D.content, children: children })] })] }));
|
|
1269
1269
|
};
|
|
1270
1270
|
|
|
1271
|
-
var styles$
|
|
1271
|
+
var styles$C = {"card":"Card-module_card__Ak6-W","default":"Card-module_default__e-M3H","bordered":"Card-module_bordered__pUL4k","elevated":"Card-module_elevated__8f-WS","interactive":"Card-module_interactive__6B4fH","padding-none":"Card-module_padding-none__c1qKN","padding-sm":"Card-module_padding-sm__Uejon","padding-md":"Card-module_padding-md__kR4F9","padding-lg":"Card-module_padding-lg__MleX9","header":"Card-module_header__NiVTV","headerContent":"Card-module_headerContent__LyJRB","title":"Card-module_title__3DN1v","subtitle":"Card-module_subtitle__gE5L-","actions":"Card-module_actions__gHmpq","body":"Card-module_body__BU4oo","footer":"Card-module_footer__zjjTd"};
|
|
1272
1272
|
|
|
1273
1273
|
/**
|
|
1274
1274
|
* Card component for grouping related content.
|
|
1275
1275
|
*/
|
|
1276
1276
|
const Card = forwardRef(({ variant = 'default', padding = 'md', interactive = false, className = '', children, ...props }, ref) => {
|
|
1277
1277
|
const classNames = [
|
|
1278
|
-
styles$
|
|
1279
|
-
styles$
|
|
1280
|
-
styles$
|
|
1281
|
-
interactive ? styles$
|
|
1278
|
+
styles$C.card,
|
|
1279
|
+
styles$C[variant],
|
|
1280
|
+
styles$C[`padding-${padding}`],
|
|
1281
|
+
interactive ? styles$C.interactive : '',
|
|
1282
1282
|
className,
|
|
1283
1283
|
]
|
|
1284
1284
|
.filter(Boolean)
|
|
@@ -1287,22 +1287,22 @@ const Card = forwardRef(({ variant = 'default', padding = 'md', interactive = fa
|
|
|
1287
1287
|
});
|
|
1288
1288
|
Card.displayName = 'Card';
|
|
1289
1289
|
const CardHeader = ({ title, subtitle, actions, className = '', children, ...props }) => {
|
|
1290
|
-
const classNames = [styles$
|
|
1291
|
-
return (jsxs("div", { className: classNames, ...props, children: [jsxs("div", { className: styles$
|
|
1290
|
+
const classNames = [styles$C.header, className].filter(Boolean).join(' ');
|
|
1291
|
+
return (jsxs("div", { className: classNames, ...props, children: [jsxs("div", { className: styles$C.headerContent, children: [title && jsx("h3", { className: styles$C.title, children: title }), subtitle && jsx("p", { className: styles$C.subtitle, children: subtitle }), children] }), actions && jsx("div", { className: styles$C.actions, children: actions })] }));
|
|
1292
1292
|
};
|
|
1293
1293
|
CardHeader.displayName = 'CardHeader';
|
|
1294
1294
|
const CardBody = ({ className = '', children, ...props }) => {
|
|
1295
|
-
const classNames = [styles$
|
|
1295
|
+
const classNames = [styles$C.body, className].filter(Boolean).join(' ');
|
|
1296
1296
|
return (jsx("div", { className: classNames, ...props, children: children }));
|
|
1297
1297
|
};
|
|
1298
1298
|
CardBody.displayName = 'CardBody';
|
|
1299
1299
|
const CardFooter = ({ className = '', children, ...props }) => {
|
|
1300
|
-
const classNames = [styles$
|
|
1300
|
+
const classNames = [styles$C.footer, className].filter(Boolean).join(' ');
|
|
1301
1301
|
return (jsx("div", { className: classNames, ...props, children: children }));
|
|
1302
1302
|
};
|
|
1303
1303
|
CardFooter.displayName = 'CardFooter';
|
|
1304
1304
|
|
|
1305
|
-
var styles$
|
|
1305
|
+
var styles$B = {"container":"ContactList-module_container__1kjze","alert":"ContactList-module_alert__KC0tz","card":"ContactList-module_card__TOyp2","header":"ContactList-module_header__QysLx","titleRow":"ContactList-module_titleRow__tUDMS","title":"ContactList-module_title__R-IOd","tooltip":"ContactList-module_tooltip__DDMka","list":"ContactList-module_list__6tjo-","contactItem":"ContactList-module_contactItem__4SoW-","contactInfo":"ContactList-module_contactInfo__6cQpi","contactName":"ContactList-module_contactName__z748K","badge":"ContactList-module_badge__USFpb","badgeSecondary":"ContactList-module_badgeSecondary__OSwqF","contactRole":"ContactList-module_contactRole__6kfuQ","contactDetails":"ContactList-module_contactDetails__ihY0M","contactLink":"ContactList-module_contactLink__sWGp9","contactPhone":"ContactList-module_contactPhone__dUn6z","contactActions":"ContactList-module_contactActions__6WT-z","actionButton":"ContactList-module_actionButton__aPnGZ","actionButtonDanger":"ContactList-module_actionButtonDanger__yRBz0","empty":"ContactList-module_empty__bRTDB","footer":"ContactList-module_footer__18gB-","addButton":"ContactList-module_addButton__STUhp"};
|
|
1306
1306
|
|
|
1307
1307
|
const InfoIcon = () => (jsxs("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: [jsx("circle", { cx: "12", cy: "12", r: "10" }), jsx("line", { x1: "12", y1: "16", x2: "12", y2: "12" }), jsx("line", { x1: "12", y1: "8", x2: "12.01", y2: "8" })] }));
|
|
1308
1308
|
const EditIcon$1 = () => (jsxs("svg", { width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: [jsx("path", { d: "M11 4H4a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7" }), jsx("path", { d: "M18.5 2.5a2.121 2.121 0 0 1 3 3L12 15l-4 1 1-4 9.5-9.5z" })] }));
|
|
@@ -1313,18 +1313,18 @@ const PlusIcon$1 = () => (jsxs("svg", { width: "16", height: "16", viewBox: "0 0
|
|
|
1313
1313
|
*/
|
|
1314
1314
|
const ContactList = ({ title = 'Contacts', tooltip, contacts, onEdit, onRemove, onAdd, showAdd = true, addLabel = 'Add Contact', alert, className = '', }) => {
|
|
1315
1315
|
const listClasses = [
|
|
1316
|
-
styles$
|
|
1316
|
+
styles$B.container,
|
|
1317
1317
|
className,
|
|
1318
1318
|
].filter(Boolean).join(' ');
|
|
1319
|
-
return (jsxs("div", { className: listClasses, children: [alert && (jsx("div", { className: styles$
|
|
1319
|
+
return (jsxs("div", { className: listClasses, children: [alert && (jsx("div", { className: styles$B.alert, children: alert })), jsxs("div", { className: styles$B.card, children: [jsx("div", { className: styles$B.header, children: jsxs("div", { className: styles$B.titleRow, children: [jsx("h3", { className: styles$B.title, children: title }), tooltip && (jsx("span", { className: styles$B.tooltip, children: jsx(InfoIcon, {}) }))] }) }), jsxs("div", { className: styles$B.list, children: [contacts.map((contact) => (jsxs("div", { className: styles$B.contactItem, children: [jsxs("div", { className: styles$B.contactInfo, children: [jsxs("div", { className: styles$B.contactName, children: [contact.name, contact.isPrimary && (jsx("span", { className: styles$B.badge, children: "Primary" })), contact.isSecondary && (jsx("span", { className: `${styles$B.badge} ${styles$B.badgeSecondary}`, children: "Secondary" }))] }), contact.role && (jsx("div", { className: styles$B.contactRole, children: contact.role })), jsxs("div", { className: styles$B.contactDetails, children: [contact.email && (jsx("a", { href: `mailto:${contact.email}`, className: styles$B.contactLink, children: contact.email })), contact.phone && (jsx("span", { className: styles$B.contactPhone, children: contact.phone }))] })] }), jsxs("div", { className: styles$B.contactActions, children: [onEdit && (jsx("button", { type: "button", className: styles$B.actionButton, onClick: () => onEdit(contact), "aria-label": "Edit contact", children: jsx(EditIcon$1, {}) })), onRemove && (jsx("button", { type: "button", className: `${styles$B.actionButton} ${styles$B.actionButtonDanger}`, onClick: () => onRemove(contact), "aria-label": "Remove contact", children: jsx(TrashIcon$1, {}) }))] })] }, contact.id))), contacts.length === 0 && (jsx("div", { className: styles$B.empty, children: "No contacts added" }))] }), showAdd && onAdd && (jsx("div", { className: styles$B.footer, children: jsxs("button", { type: "button", className: styles$B.addButton, onClick: onAdd, children: [jsx(PlusIcon$1, {}), addLabel] }) }))] })] }));
|
|
1320
1320
|
};
|
|
1321
1321
|
ContactList.displayName = 'ContactList';
|
|
1322
1322
|
|
|
1323
|
-
var styles$
|
|
1323
|
+
var styles$A = {"container":"Drawer-module_container__hXuOY","backdrop":"Drawer-module_backdrop__MIipQ","fadeIn":"Drawer-module_fadeIn__QsuvQ","backdropOpen":"Drawer-module_backdropOpen__YpH--","drawer":"Drawer-module_drawer__EHbbs","right":"Drawer-module_right__x6P6Q","drawerOpen":"Drawer-module_drawerOpen__KTgFg","left":"Drawer-module_left__aVF9t","top":"Drawer-module_top__wuvhi","bottom":"Drawer-module_bottom__rt-VZ","sizeSm":"Drawer-module_sizeSm__LFrm3","sizeMd":"Drawer-module_sizeMd__A1QTQ","sizeLg":"Drawer-module_sizeLg__6laD8","sizeXl":"Drawer-module_sizeXl__FY9mZ","sizeFull":"Drawer-module_sizeFull__BGQ1q","header":"Drawer-module_header__MpR14","headerContent":"Drawer-module_headerContent__dFcLH","title":"Drawer-module_title__0AmOX","closeButton":"Drawer-module_closeButton__VuXsE","body":"Drawer-module_body__GLUGo","footer":"Drawer-module_footer__K5ekS"};
|
|
1324
1324
|
|
|
1325
|
-
const DrawerHeader = ({ title, children, showClose = true, onClose, className = '', }) => (jsxs("div", { className: `${styles$
|
|
1326
|
-
const DrawerBody = ({ children, className = '' }) => (jsx("div", { className: `${styles$
|
|
1327
|
-
const DrawerFooter = ({ children, className = '' }) => (jsx("div", { className: `${styles$
|
|
1325
|
+
const DrawerHeader = ({ title, children, showClose = true, onClose, className = '', }) => (jsxs("div", { className: `${styles$A.header} ${className}`, children: [jsxs("div", { className: styles$A.headerContent, children: [title && jsx("h2", { className: styles$A.title, children: title }), children] }), showClose && (jsx("button", { type: "button", className: styles$A.closeButton, onClick: onClose, "aria-label": "Close drawer", children: jsx("svg", { width: "20", height: "20", fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M6 18L18 6M6 6l12 12" }) }) }))] }));
|
|
1326
|
+
const DrawerBody = ({ children, className = '' }) => (jsx("div", { className: `${styles$A.body} ${className}`, children: children }));
|
|
1327
|
+
const DrawerFooter = ({ children, className = '' }) => (jsx("div", { className: `${styles$A.footer} ${className}`, children: children }));
|
|
1328
1328
|
const Drawer = ({ isOpen, onClose, position = 'right', size = 'md', children, closeOnBackdropClick = true, closeOnEscape = true, showBackdrop = true, className = '', }) => {
|
|
1329
1329
|
const handleEscape = useCallback((e) => {
|
|
1330
1330
|
if (closeOnEscape && e.key === 'Escape') {
|
|
@@ -1348,7 +1348,7 @@ const Drawer = ({ isOpen, onClose, position = 'right', size = 'md', children, cl
|
|
|
1348
1348
|
};
|
|
1349
1349
|
if (!isOpen)
|
|
1350
1350
|
return null;
|
|
1351
|
-
return (jsxs("div", { className: styles$
|
|
1351
|
+
return (jsxs("div", { className: styles$A.container, children: [showBackdrop && (jsx("div", { className: `${styles$A.backdrop} ${isOpen ? styles$A.backdropOpen : ''}`, onClick: handleBackdropClick })), jsx("div", { className: `${styles$A.drawer} ${styles$A[position]} ${styles$A[`size${size.charAt(0).toUpperCase()}${size.slice(1)}`]} ${isOpen ? styles$A.drawerOpen : ''} ${className}`, role: "dialog", "aria-modal": "true", children: React.Children.map(children, (child) => {
|
|
1352
1352
|
if (React.isValidElement(child) && child.type === DrawerHeader) {
|
|
1353
1353
|
return React.cloneElement(child, {
|
|
1354
1354
|
onClose,
|
|
@@ -1361,7 +1361,7 @@ Drawer.Header = DrawerHeader;
|
|
|
1361
1361
|
Drawer.Body = DrawerBody;
|
|
1362
1362
|
Drawer.Footer = DrawerFooter;
|
|
1363
1363
|
|
|
1364
|
-
var styles$
|
|
1364
|
+
var styles$z = {"drawer":"DueDatesDrawer-module_drawer__TqC4Q","open":"DueDatesDrawer-module_open__Yblf3","body":"DueDatesDrawer-module_body__OwwF-","search":"DueDatesDrawer-module_search__g7-Rl","cards":"DueDatesDrawer-module_cards__bFG90","empty":"DueDatesDrawer-module_empty__K2ULN","card":"DueDatesDrawer-module_card__4Os-5","cardTitle":"DueDatesDrawer-module_cardTitle__fU-cP","status":"DueDatesDrawer-module_status__dXifz","completed":"DueDatesDrawer-module_completed__jWoYi","pastDue":"DueDatesDrawer-module_pastDue__TSikC","tags":"DueDatesDrawer-module_tags__8P87y","completion":"DueDatesDrawer-module_completion__mIrWm"};
|
|
1365
1365
|
|
|
1366
1366
|
const isTravelDueDateCompleted = (item) => item.status.trim().toLowerCase() === 'completed' || !!item.completeddatetime;
|
|
1367
1367
|
const parseLocalDate$1 = (value) => {
|
|
@@ -1377,7 +1377,7 @@ const DueDateCard$1 = ({ item, onToggle, onTaskClick }) => {
|
|
|
1377
1377
|
const completed = isTravelDueDateCompleted(item);
|
|
1378
1378
|
const dueDate = parseLocalDate$1(item.duedate);
|
|
1379
1379
|
const pastDue = !!dueDate && dueDate < new Date() && !completed;
|
|
1380
|
-
return (jsxs("article", { className: styles$
|
|
1380
|
+
return (jsxs("article", { className: styles$z.card, children: [jsxs("div", { className: styles$z.cardTitle, children: [jsx("button", { type: "button", "aria-label": `${completed ? 'Reopen' : 'Complete'} ${item.tasktitle}`, className: [styles$z.status, completed ? styles$z.completed : pastDue ? styles$z.pastDue : ''].filter(Boolean).join(' '), onClick: () => onToggle?.(item), children: completed ? jsx(CheckIcon$2, { size: 12 }) : null }), jsx("h5", { children: item.tasktitle })] }), item.description && jsx("p", { children: item.description }), jsxs("div", { className: styles$z.tags, children: [jsx("span", { style: { backgroundColor: sportColor$1(item.sportCode) }, children: item.sportCode }), jsx("button", { type: "button", disabled: !item.masterTripGUID || !onTaskClick, onClick: () => item.masterTripGUID && onTaskClick?.(item.masterTripGUID), children: item.tripName })] }), completed && item.completeddatetime && jsxs("div", { className: styles$z.completion, children: [jsx(CheckIcon$2, { size: 14 }), jsxs("span", { children: [jsx("em", { children: "on" }), " ", formatDate$2(item.completeddatetime, { month: 'numeric', day: 'numeric', year: '2-digit' }), " ", jsx("em", { children: "by" }), " ", item.completedby] })] })] }));
|
|
1381
1381
|
};
|
|
1382
1382
|
/** Hub's searchable, status-aware due-dates drawer. */
|
|
1383
1383
|
const DueDatesDrawer = ({ isOpen, dueDates, selectedDate, selectedTrip, onClose, onToggle, onTaskClick, className = '' }) => {
|
|
@@ -1389,10 +1389,10 @@ const DueDatesDrawer = ({ isOpen, dueDates, selectedDate, selectedTrip, onClose,
|
|
|
1389
1389
|
const matches = items.filter((item) => (!selectedTrip || item.masterTripGUID === String(selectedTrip)) && (!normalized || item.tasktitle.toLowerCase().includes(normalized) || item.sportCode.toLowerCase().includes(normalized) || item.description.toLowerCase().includes(normalized)));
|
|
1390
1390
|
return matches.length ? [[date, matches]] : [];
|
|
1391
1391
|
})), [dueDates, search, selectedDate, selectedTrip]);
|
|
1392
|
-
return (jsxs("aside", { className: [styles$
|
|
1392
|
+
return (jsxs("aside", { className: [styles$z.drawer, isOpen ? styles$z.open : '', className].filter(Boolean).join(' '), "aria-hidden": !isOpen, "aria-label": "Due Dates", children: [jsxs("header", { children: [jsx("h3", { children: "Due Dates" }), jsx("button", { type: "button", "aria-label": "Close due dates", onClick: onClose, children: jsx(CloseIcon, { size: 24 }) })] }), jsxs("div", { className: styles$z.body, children: [jsxs("label", { className: styles$z.search, children: [jsx(SearchIcon$1, { size: 16 }), jsx("input", { type: "search", placeholder: "Search", value: search, onChange: (event) => setSearch(event.target.value) })] }), !Object.keys(filtered).length ? jsx("div", { className: styles$z.empty, children: "No due dates found." }) : Object.entries(filtered).map(([date, items]) => (jsxs("section", { children: [jsx("h4", { children: formatDate$2(date, { month: 'long', day: 'numeric', year: 'numeric' }) }), jsx("div", { className: styles$z.cards, children: items.map((item) => jsx(DueDateCard$1, { item: item, onToggle: onToggle, onTaskClick: onTaskClick }, `${date}-${item.taskid}`)) })] }, date)))] })] }));
|
|
1393
1393
|
};
|
|
1394
1394
|
|
|
1395
|
-
var styles$
|
|
1395
|
+
var styles$y = {"shell":"HubAppShell-module_shell__Y13Fo","main":"HubAppShell-module_main__OvnjA","beta":"HubAppShell-module_beta__V8Dzh","sidebar":"HubAppShell-module_sidebar__73gt6","shellExpanded":"HubAppShell-module_shellExpanded__z9cLL","expandButton":"HubAppShell-module_expandButton__hyYi-","logo":"HubAppShell-module_logo__iylLM","defaultLogo":"HubAppShell-module_defaultLogo__tVCz-","desktopNav":"HubAppShell-module_desktopNav__-ZRGD","navItem":"HubAppShell-module_navItem__FKkXN","active":"HubAppShell-module_active__zu1-B","navIcon":"HubAppShell-module_navIcon__QRImh","disabledNav":"HubAppShell-module_disabledNav__zj07n","sidebarFooter":"HubAppShell-module_sidebarFooter__kA2bq","profile":"HubAppShell-module_profile__JCGL5","avatar":"HubAppShell-module_avatar__V-lFG","profileMenu":"HubAppShell-module_profileMenu__qqWSu","topbar":"HubAppShell-module_topbar__U4w0A","defaultAccount":"HubAppShell-module_defaultAccount__3vohz","defaultActions":"HubAppShell-module_defaultActions__wAEJb","desktopActions":"HubAppShell-module_desktopActions__uVRKY","mobileActions":"HubAppShell-module_mobileActions__W6Rf9","content":"HubAppShell-module_content__yCgGs","contentDisabled":"HubAppShell-module_contentDisabled__btmCY","mobileNav":"HubAppShell-module_mobileNav__X0zBs","mobileNavItem":"HubAppShell-module_mobileNavItem__1x94j","mobileExtras":"HubAppShell-module_mobileExtras__xo3qI","mobileBooking":"HubAppShell-module_mobileBooking__-Jz9h","mobilePrimary":"HubAppShell-module_mobilePrimary__p5PCn","mobileFooter":"HubAppShell-module_mobileFooter__QvsE-","loading":"HubAppShell-module_loading__V8RiG"};
|
|
1396
1396
|
|
|
1397
1397
|
const HUB_INDIVIDUAL_TRAVEL_ITEM = { key: 'individual-travel', label: 'Individual Travel', path: '/individual-travel', icon: jsx(UserIcon, { size: 24 }) };
|
|
1398
1398
|
const HUB_NAV_ITEMS = [
|
|
@@ -1402,9 +1402,9 @@ const HUB_NAV_ITEMS = [
|
|
|
1402
1402
|
{ key: 'team-management', label: 'Team Management', path: '/team-management', icon: jsx(UsersIcon$1, { size: 24 }) },
|
|
1403
1403
|
];
|
|
1404
1404
|
const HUB_ADMIN_ITEM = { key: 'administration', label: 'Administration', path: '/administration', icon: jsx(SettingsIcon, { size: 24 }) };
|
|
1405
|
-
const DefaultLogo = ({ expanded }) => jsxs("div", { className: styles$
|
|
1406
|
-
const DefaultAccount = () => jsxs("button", { type: "button", className: styles$
|
|
1407
|
-
const DefaultActions = ({ isMobileNavOpen, toggleMobileNav }) => (jsxs("div", { className: styles$
|
|
1405
|
+
const DefaultLogo = ({ expanded }) => jsxs("div", { className: styles$y.defaultLogo, children: [jsx(LogoIcon, { size: expanded ? 38 : 32 }), expanded && jsxs("span", { children: [jsx("strong", { children: "SHORT'S" }), jsx("small", { children: "TRAVEL MANAGEMENT" })] })] });
|
|
1406
|
+
const DefaultAccount = () => jsxs("button", { type: "button", className: styles$y.defaultAccount, children: [jsx("span", { children: "UNI" }), jsx("strong", { children: "University of Northern Iowa" })] });
|
|
1407
|
+
const DefaultActions = ({ isMobileNavOpen, toggleMobileNav }) => (jsxs("div", { className: styles$y.defaultActions, children: [jsxs("div", { className: styles$y.desktopActions, children: [jsx(Button, { size: "lg", leftIcon: jsx(ArrowUpRightIcon, { size: 18 }), children: "Book Team Travel" }), jsx(Button, { variant: "secondary", size: "lg", square: true, "aria-label": "Provide Feedback", children: jsx(LightbulbIcon, { size: 18 }) }), jsx(Button, { variant: "secondary", size: "lg", square: true, "aria-label": "Announcements", children: jsx(MegaphoneIcon, { size: 18 }) }), jsx(Button, { variant: "secondary", size: "lg", square: true, "aria-label": "Contact Us", children: jsx(PhoneIcon, { size: 18 }) })] }), jsxs("div", { className: styles$y.mobileActions, children: [jsx(Button, { variant: "ghost", size: "lg", square: true, "aria-label": "Announcements", children: jsx(MegaphoneIcon, { size: 20 }) }), jsx(Button, { variant: "ghost", size: "lg", square: true, "aria-label": isMobileNavOpen ? 'Close navigation' : 'Open navigation', onClick: toggleMobileNav, children: isMobileNavOpen ? jsx(CloseIcon, { size: 22 }) : jsx(MenuIcon, { size: 22 }) })] })] }));
|
|
1408
1408
|
/** The shared application navigation and content shell used by Hub and its Storybook pages. */
|
|
1409
1409
|
const HubAppShell = ({ children, navItems = HUB_NAV_ITEMS, individualTravelItem = HUB_INDIVIDUAL_TRAVEL_ITEM, adminItem = HUB_ADMIN_ITEM, activeNavKey, onNavigate, onLogoClick, onLegacyPortal, accountSelector, renderTopbarActions, renderMobileExtras, mobileFooter, profileMenu, userInitials = 'KM', isAdmin = true, navigationDisabled = false, loading = false, contentDisabled = false, showContent = true, logo, defaultExpanded = false, betaLabel = 'Beta Version', className = '', }) => {
|
|
1410
1410
|
const [expanded, setExpanded] = useState(defaultExpanded);
|
|
@@ -1427,11 +1427,11 @@ const HubAppShell = ({ children, navItems = HUB_NAV_ITEMS, individualTravelItem
|
|
|
1427
1427
|
onNavigate?.(item);
|
|
1428
1428
|
closeMobileNav();
|
|
1429
1429
|
};
|
|
1430
|
-
const renderNavItem = (item, mobile = false) => (jsxs("button", { type: "button", className: [styles$
|
|
1431
|
-
return (jsxs("div", { className: [styles$
|
|
1430
|
+
const renderNavItem = (item, mobile = false) => (jsxs("button", { type: "button", className: [styles$y.navItem, activeNavKey === item.key ? styles$y.active : '', mobile ? styles$y.mobileNavItem : ''].filter(Boolean).join(' '), "aria-current": activeNavKey === item.key ? 'page' : undefined, "aria-label": item.label, title: item.label, onClick: () => navigate(item), children: [jsx("span", { className: styles$y.navIcon, children: item.icon }), (expanded || mobile) && jsx("span", { children: item.label })] }, item.key));
|
|
1431
|
+
return (jsxs("div", { className: [styles$y.shell, expanded ? styles$y.shellExpanded : '', className].filter(Boolean).join(' '), children: [loading && jsx("div", { className: styles$y.loading, role: "status", "aria-label": "Loading", "data-testid": "loading-overlay", children: jsx("span", {}) }), betaLabel && jsx("div", { className: styles$y.beta, children: betaLabel }), jsxs("aside", { className: styles$y.sidebar, "data-expanded": expanded, children: [jsx("button", { type: "button", className: styles$y.expandButton, "aria-label": expanded ? 'Collapse sidebar' : 'Expand sidebar', onClick: () => setExpanded((value) => !value), children: expanded ? jsx(ChevronLeftIcon, { size: 16 }) : jsx(ChevronRightIcon$1, { size: 16 }) }), jsx("button", { type: "button", className: styles$y.logo, "aria-label": "Go to Home", onClick: onLogoClick, children: logo ?? jsx(DefaultLogo, { expanded: expanded }) }), jsxs("nav", { className: styles$y.desktopNav, "aria-label": "Hub navigation", children: [jsxs("button", { type: "button", className: styles$y.navItem, "aria-label": "Old Portal", title: "Old Portal", onClick: onLegacyPortal, children: [jsx("span", { className: styles$y.navIcon, children: jsx(ArrowUpRightIcon, { size: 24 }) }), expanded && jsx("span", { children: "Old Portal" })] }), renderNavItem(individualTravelItem), jsx("div", { className: navigationDisabled ? styles$y.disabledNav : '', children: navItems.map((item) => renderNavItem(item)) })] }), jsxs("div", { className: styles$y.sidebarFooter, children: [isAdmin && renderNavItem(adminItem), jsxs("div", { className: styles$y.profile, ref: profileRef, children: [jsx("button", { type: "button", className: styles$y.avatar, "aria-label": "User Information", onClick: () => setIsProfileOpen((value) => !value), children: userInitials }), isProfileOpen && profileMenu && jsx("div", { className: styles$y.profileMenu, children: profileMenu })] })] })] }), jsxs("div", { className: styles$y.main, children: [jsxs("header", { className: styles$y.topbar, children: [jsx("div", { children: accountSelector ?? jsx(DefaultAccount, {}) }), renderTopbarActions?.(actions) ?? jsx(DefaultActions, { ...actions })] }), isMobileNavOpen && jsxs("div", { className: styles$y.mobileNav, children: [jsx("nav", { "aria-label": "Mobile Hub navigation", children: navItems.map((item) => renderNavItem(item, true)) }), jsxs("div", { className: styles$y.mobileExtras, role: "group", "aria-label": "Mobile navigation actions", children: [renderMobileExtras?.(closeMobileNav) ?? jsxs("button", { type: "button", className: styles$y.mobileBooking, onClick: closeMobileNav, children: [jsx(ArrowUpRightIcon, { size: 20 }), jsx("span", { children: "Book Team Travel" })] }), jsxs("button", { type: "button", className: styles$y.mobilePrimary, onClick: () => { onLegacyPortal?.(); closeMobileNav(); }, children: [jsx(ArrowUpRightIcon, { size: 20 }), jsx("span", { children: "Legacy Portal" })] })] }), mobileFooter && jsx("div", { className: styles$y.mobileFooter, children: mobileFooter })] }), showContent && jsx("main", { className: [styles$y.content, contentDisabled ? styles$y.contentDisabled : ''].filter(Boolean).join(' '), children: children })] })] }));
|
|
1432
1432
|
};
|
|
1433
1433
|
|
|
1434
|
-
var styles$
|
|
1434
|
+
var styles$x = {"container":"MembershipPrograms-module_container__qsGZu","loading":"MembershipPrograms-module_loading__tjDtr","alert":"MembershipPrograms-module_alert__GZc0f","header":"MembershipPrograms-module_header__ywXOE","title":"MembershipPrograms-module_title__WZGyt","addButton":"MembershipPrograms-module_addButton__rNlNb","empty":"MembershipPrograms-module_empty__pYrHW","list":"MembershipPrograms-module_list__8A9MG","group":"MembershipPrograms-module_group__v1Vc6","groupHeader":"MembershipPrograms-module_groupHeader__I5KJO","groupIcon":"MembershipPrograms-module_groupIcon__e1LIq","groupLabel":"MembershipPrograms-module_groupLabel__Wqift","programs":"MembershipPrograms-module_programs__hxHXQ","program":"MembershipPrograms-module_program__S3HTM","programInfo":"MembershipPrograms-module_programInfo__RJruG","programProvider":"MembershipPrograms-module_programProvider__c7enz","programName":"MembershipPrograms-module_programName__TN42s","programNumber":"MembershipPrograms-module_programNumber__GKav4","programStatus":"MembershipPrograms-module_programStatus__2imvX","programActions":"MembershipPrograms-module_programActions__36LkY","actionButton":"MembershipPrograms-module_actionButton__y-GI4","removeButton":"MembershipPrograms-module_removeButton__cTTuZ"};
|
|
1435
1435
|
|
|
1436
1436
|
const PlaneIcon$1 = () => (jsx("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: jsx("path", { d: "M21 16v-2l-8-5V3.5a1.5 1.5 0 0 0-3 0V9l-8 5v2l8-2.5V19l-2 1.5V22l3.5-1 3.5 1v-1.5L13 19v-5.5l8 2.5Z" }) }));
|
|
1437
1437
|
const HotelIcon$1 = () => (jsxs("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: [jsx("path", { d: "M3 21h18" }), jsx("path", { d: "M19 21V5a2 2 0 0 0-2-2H7a2 2 0 0 0-2 2v16" }), jsx("path", { d: "M9 21v-4a2 2 0 0 1 2-2h2a2 2 0 0 1 2 2v4" })] }));
|
|
@@ -1457,8 +1457,8 @@ const TYPE_LABELS = {
|
|
|
1457
1457
|
*/
|
|
1458
1458
|
const MembershipPrograms = ({ title = 'Membership Programs', programs, onEdit, onRemove, onAdd, alert, isLoading = false, emptyMessage = 'No membership programs added', className = '', }) => {
|
|
1459
1459
|
const containerClasses = [
|
|
1460
|
-
styles$
|
|
1461
|
-
isLoading ? styles$
|
|
1460
|
+
styles$x.container,
|
|
1461
|
+
isLoading ? styles$x.loading : '',
|
|
1462
1462
|
className,
|
|
1463
1463
|
].filter(Boolean).join(' ');
|
|
1464
1464
|
const groupedPrograms = programs.reduce((acc, program) => {
|
|
@@ -1469,30 +1469,30 @@ const MembershipPrograms = ({ title = 'Membership Programs', programs, onEdit, o
|
|
|
1469
1469
|
return acc;
|
|
1470
1470
|
}, {});
|
|
1471
1471
|
const typeOrder = ['airline', 'hotel', 'car', 'other'];
|
|
1472
|
-
return (jsxs("div", { className: containerClasses, children: [alert && jsx("div", { className: styles$
|
|
1472
|
+
return (jsxs("div", { className: containerClasses, children: [alert && jsx("div", { className: styles$x.alert, children: alert }), jsxs("div", { className: styles$x.header, children: [jsx("h2", { className: styles$x.title, children: title }), onAdd && (jsxs("button", { type: "button", className: styles$x.addButton, onClick: onAdd, "aria-label": "Add membership program", children: [jsx(PlusIcon, {}), jsx("span", { children: "Add Program" })] }))] }), programs.length === 0 ? (jsx("div", { className: styles$x.empty, children: jsx("p", { children: emptyMessage }) })) : (jsx("div", { className: styles$x.list, children: typeOrder.map((type) => {
|
|
1473
1473
|
const typePrograms = groupedPrograms[type];
|
|
1474
1474
|
if (!typePrograms || typePrograms.length === 0)
|
|
1475
1475
|
return null;
|
|
1476
|
-
return (jsxs("div", { className: styles$
|
|
1476
|
+
return (jsxs("div", { className: styles$x.group, children: [jsxs("div", { className: styles$x.groupHeader, children: [jsx("span", { className: styles$x.groupIcon, children: TYPE_ICONS[type] }), jsx("span", { className: styles$x.groupLabel, children: TYPE_LABELS[type] })] }), jsx("div", { className: styles$x.programs, children: typePrograms.map((program) => (jsxs("div", { className: styles$x.program, children: [jsxs("div", { className: styles$x.programInfo, children: [jsx("div", { className: styles$x.programProvider, children: program.provider }), program.programName && (jsx("div", { className: styles$x.programName, children: program.programName })), jsx("div", { className: styles$x.programNumber, children: program.membershipNumber }), program.status && (jsx("div", { className: styles$x.programStatus, children: program.status }))] }), jsxs("div", { className: styles$x.programActions, children: [onEdit && (jsx("button", { type: "button", className: styles$x.actionButton, onClick: () => onEdit(program), "aria-label": `Edit ${program.provider} program`, children: jsx(EditIcon, {}) })), onRemove && (jsx("button", { type: "button", className: [styles$x.actionButton, styles$x.removeButton].join(' '), onClick: () => onRemove(program), "aria-label": `Remove ${program.provider} program`, children: jsx(TrashIcon, {}) }))] })] }, program.id))) })] }, type));
|
|
1477
1477
|
}) }))] }));
|
|
1478
1478
|
};
|
|
1479
1479
|
MembershipPrograms.displayName = 'MembershipPrograms';
|
|
1480
1480
|
|
|
1481
|
-
var styles$
|
|
1481
|
+
var styles$w = {"stats":"ManifestCapacityStats-module_stats__BA5-o","stat":"ManifestCapacityStats-module_stat__qLJtb","labelRow":"ManifestCapacityStats-module_labelRow__iDQqn","label":"ManifestCapacityStats-module_label__5BRoZ","value":"ManifestCapacityStats-module_value__4hiE5","sub":"ManifestCapacityStats-module_sub__w7djZ","warningText":"ManifestCapacityStats-module_warningText__CZZ9a","warningIcon":"ManifestCapacityStats-module_warningIcon__NoXmW","alertIcon":"ManifestCapacityStats-module_alertIcon__h0QHJ","meter":"ManifestCapacityStats-module_meter__DrUuq","meterFill":"ManifestCapacityStats-module_meterFill__v7zKW","meterOver":"ManifestCapacityStats-module_meterOver__UqigI","alert":"ManifestCapacityStats-module_alert__vwkBX"};
|
|
1482
1482
|
|
|
1483
1483
|
const Stat = ({ label, value, sub, meterValue, meterMax, warn = false }) => {
|
|
1484
1484
|
const ratio = meterMax > 0 ? Math.min(100, Math.max(0, (meterValue / meterMax) * 100)) : 0;
|
|
1485
|
-
return (jsxs("div", { className: styles$
|
|
1485
|
+
return (jsxs("div", { className: styles$w.stat, children: [jsxs("div", { className: styles$w.labelRow, children: [jsx("span", { className: styles$w.label, children: label }), warn && jsx(WarningIcon$1, { size: 14, className: styles$w.warningIcon, "aria-label": `${label} warning` })] }), jsx("div", { className: [styles$w.value, warn ? styles$w.warningText : ''].filter(Boolean).join(' '), children: value }), jsx("div", { className: styles$w.sub, children: sub }), jsx("div", { className: styles$w.meter, "aria-hidden": "true", children: jsx("span", { className: [styles$w.meterFill, warn ? styles$w.meterOver : ''].filter(Boolean).join(' '), style: { width: `${ratio}%` } }) })] }));
|
|
1486
1486
|
};
|
|
1487
1487
|
/** Advisory seat and payload meters from Hub's charter manifest. */
|
|
1488
1488
|
const ManifestCapacityStats = ({ paxCount, seats, paxWeight, cargoWeight, payloadLimit, className = '', }) => {
|
|
1489
1489
|
const totalWeight = paxWeight + cargoWeight;
|
|
1490
1490
|
const overSeats = seats > 0 && paxCount > seats;
|
|
1491
1491
|
const overPayload = payloadLimit > 0 && totalWeight > payloadLimit;
|
|
1492
|
-
return (jsxs("div", { className: className, children: [jsxs("div", { className: styles$
|
|
1492
|
+
return (jsxs("div", { className: className, children: [jsxs("div", { className: styles$w.stats, children: [jsx(Stat, { label: "Seats", value: `${paxCount} / ${seats}`, sub: overSeats ? `${paxCount - seats} over capacity` : `${Math.max(0, seats - paxCount)} seats open`, meterValue: paxCount, meterMax: seats, warn: overSeats }), jsx(Stat, { label: "Passenger weight", value: `${paxWeight.toLocaleString()} lb`, sub: `${paxCount} passengers`, meterValue: paxWeight, meterMax: payloadLimit }), jsx(Stat, { label: "Cargo weight", value: `${cargoWeight.toLocaleString()} lb`, sub: "Equipment + bags", meterValue: cargoWeight, meterMax: payloadLimit }), jsx(Stat, { label: "Total payload", value: `${totalWeight.toLocaleString()} lb`, sub: overPayload ? `${(totalWeight - payloadLimit).toLocaleString()} lb over limit` : `Limit ${payloadLimit.toLocaleString()} lb`, meterValue: totalWeight, meterMax: payloadLimit, warn: overPayload })] }), (overSeats || overPayload) && (jsxs("div", { className: styles$w.alert, role: "alert", children: [jsx(WarningIcon$1, { size: 20, className: styles$w.alertIcon }), jsxs("div", { children: [overSeats && (jsxs("div", { children: [jsx("strong", { children: "Over seat capacity." }), " Remove ", paxCount - seats, " passenger(s) or split the manifest by segment."] })), overPayload && (jsxs("div", { children: [jsx("strong", { children: "Over the contracted payload." }), " Total payload exceeds the quoted maximum \u2014 coordinate with the team/client and confirm with the carrier before sending."] }))] })] }))] }));
|
|
1493
1493
|
};
|
|
1494
1494
|
|
|
1495
|
-
var styles$
|
|
1495
|
+
var styles$v = {"overlay":"Modal-module_overlay__n7Paz","fadeIn":"Modal-module_fadeIn__upWKg","modal":"Modal-module_modal__YZQ-K","slideIn":"Modal-module_slideIn__mtAFr","sm":"Modal-module_sm__QSWSJ","md":"Modal-module_md__6t9J8","lg":"Modal-module_lg__5r3uQ","xl":"Modal-module_xl__JPpjn","full":"Modal-module_full__y9leS","header":"Modal-module_header__xTw6j","title":"Modal-module_title__KvPHy","closeButton":"Modal-module_closeButton__JoRui","body":"Modal-module_body__K3swC","footer":"Modal-module_footer__Z1UcB","footerButtons":"Modal-module_footerButtons__u-Ayv","confirmMessage":"Modal-module_confirmMessage__ZlKV8"};
|
|
1496
1496
|
|
|
1497
1497
|
const Modal = ({ isOpen, onClose, title, children, size = 'md', showCloseButton = true, closeOnBackdropClick = true, closeOnEscape = true, footer, className = '', }) => {
|
|
1498
1498
|
const handleEscape = useCallback((e) => {
|
|
@@ -1517,12 +1517,12 @@ const Modal = ({ isOpen, onClose, title, children, size = 'md', showCloseButton
|
|
|
1517
1517
|
};
|
|
1518
1518
|
if (!isOpen)
|
|
1519
1519
|
return null;
|
|
1520
|
-
return (jsx("div", { className: styles$
|
|
1520
|
+
return (jsx("div", { className: styles$v.overlay, onClick: handleBackdropClick, children: jsxs("div", { className: `${styles$v.modal} ${styles$v[size]} ${className}`, role: "dialog", "aria-modal": "true", "aria-labelledby": title ? 'modal-title' : undefined, children: [(title || showCloseButton) && (jsxs("div", { className: styles$v.header, children: [title && (jsx("h2", { id: "modal-title", className: styles$v.title, children: title })), showCloseButton && (jsx("button", { type: "button", className: styles$v.closeButton, onClick: onClose, "aria-label": "Close modal", children: jsx("svg", { width: "20", height: "20", fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M6 18L18 6M6 6l12 12" }) }) }))] })), jsx("div", { className: styles$v.body, children: children }), footer && jsx("div", { className: styles$v.footer, children: footer })] }) }));
|
|
1521
1521
|
};
|
|
1522
|
-
const ModalFooter = ({ children, className = '' }) => (jsx("div", { className: `${styles$
|
|
1523
|
-
const ConfirmModal = ({ message, confirmText = 'Confirm', cancelText = 'Cancel', onConfirm, onClose, destructive = false, loading = false, ...props }) => (jsx(Modal, { ...props, onClose: onClose, size: "sm", footer: jsxs(ModalFooter, { children: [jsx(Button, { variant: "secondary", onClick: onClose, children: cancelText }), jsx(Button, { variant: destructive ? 'danger' : 'primary', onClick: onConfirm, disabled: loading, children: loading ? 'Loading...' : confirmText })] }), children: jsx("div", { className: styles$
|
|
1522
|
+
const ModalFooter = ({ children, className = '' }) => (jsx("div", { className: `${styles$v.footerButtons} ${className}`, children: children }));
|
|
1523
|
+
const ConfirmModal = ({ message, confirmText = 'Confirm', cancelText = 'Cancel', onConfirm, onClose, destructive = false, loading = false, ...props }) => (jsx(Modal, { ...props, onClose: onClose, size: "sm", footer: jsxs(ModalFooter, { children: [jsx(Button, { variant: "secondary", onClick: onClose, children: cancelText }), jsx(Button, { variant: destructive ? 'danger' : 'primary', onClick: onConfirm, disabled: loading, children: loading ? 'Loading...' : confirmText })] }), children: jsx("div", { className: styles$v.confirmMessage, children: message }) }));
|
|
1524
1524
|
|
|
1525
|
-
var styles$
|
|
1525
|
+
var styles$u = {"module":"Module-module_module__1Lglz","header":"Module-module_header__-qP6m","closed":"Module-module_closed__J5FYJ","sm":"Module-module_sm__g-iVI","md":"Module-module_md__zmKQE","lg":"Module-module_lg__5uVgV","titleRow":"Module-module_titleRow__3upJc","icon":"Module-module_icon__MXVy7","iconSpaced":"Module-module_iconSpaced__O8F0i","title":"Module-module_title__Qdyv0","badge":"Module-module_badge__zoNEC","tools":"Module-module_tools__w6Z1b","toggleBtn":"Module-module_toggleBtn__VxH2u","bodyWrapper":"Module-module_bodyWrapper__IogVT","body":"Module-module_body__O9n9B","hidden":"Module-module_hidden__mmUYg","footer":"Module-module_footer__hrUY9","divider":"Module-module_divider__YQKdf","dark":"Module-module_dark__w8Fb-","verticalDivider":"Module-module_verticalDivider__t3g-3"};
|
|
1526
1526
|
|
|
1527
1527
|
const ChevronIcon = ({ direction }) => (jsx("svg", { width: "24", height: "24", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", style: { transform: direction === 'up' ? 'rotate(180deg)' : 'none' }, children: jsx("polyline", { points: "6 9 12 15 18 9" }) }));
|
|
1528
1528
|
/**
|
|
@@ -1544,19 +1544,19 @@ const Module = ({ title, icon, iconClassName = '', badge, before, children, afte
|
|
|
1544
1544
|
setOpen(!open);
|
|
1545
1545
|
}
|
|
1546
1546
|
};
|
|
1547
|
-
return (jsxs("div", { className: `${styles$
|
|
1547
|
+
return (jsxs("div", { className: `${styles$u.module} ${className}`, children: [title && (jsx("div", { className: `${styles$u.header} ${styles$u[size]} ${!open ? styles$u.closed : ''} ${headerClassName}`, children: jsxs("div", { className: `${styles$u.titleRow} ${styles$u[size]} ${titleClassName}`, children: [icon && (jsx("span", { className: `${styles$u.icon} ${size === 'sm' ? '' : styles$u.iconSpaced} ${iconClassName}`, children: icon })), jsx("div", { className: styles$u.title, children: title }), badge && jsx("span", { className: styles$u.badge, children: badge }), jsxs("div", { className: styles$u.tools, children: [tools, useToggle && (jsx("button", { type: "button", className: styles$u.toggleBtn, onClick: handleToggle, "aria-expanded": open, children: jsx(ChevronIcon, { direction: open ? 'up' : 'down' }) }))] })] }) })), jsxs("div", { className: styles$u.bodyWrapper, children: [before, jsx("div", { className: `${styles$u.body} ${styles$u[size]} ${!open ? styles$u.hidden : ''} ${bodyClassName}`, children: children }), after] }), footer && (jsx("div", { className: `${styles$u.footer} ${!open ? styles$u.hidden : ''}`, children: footer }))] }));
|
|
1548
1548
|
};
|
|
1549
1549
|
/**
|
|
1550
1550
|
* Horizontal divider for Module content
|
|
1551
1551
|
*/
|
|
1552
|
-
const ModuleDivider = ({ dark = false, className = '' }) => (jsx("hr", { className: `${styles$
|
|
1552
|
+
const ModuleDivider = ({ dark = false, className = '' }) => (jsx("hr", { className: `${styles$u.divider} ${dark ? styles$u.dark : ''} ${className}` }));
|
|
1553
1553
|
/**
|
|
1554
1554
|
* Vertical divider for Module content
|
|
1555
1555
|
*/
|
|
1556
|
-
const ModuleVerticalDivider = ({ dark = false, className = '' }) => (jsx("div", { className: `${styles$
|
|
1556
|
+
const ModuleVerticalDivider = ({ dark = false, className = '' }) => (jsx("div", { className: `${styles$u.verticalDivider} ${dark ? styles$u.dark : ''} ${className}` }));
|
|
1557
1557
|
Module.displayName = 'Module';
|
|
1558
1558
|
|
|
1559
|
-
var styles$
|
|
1559
|
+
var styles$t = {"stack":"PageBanners-module_stack__v6nwz","banner":"PageBanners-module_banner__8lgnU","system":"PageBanners-module_system__Xiqoe","alert":"PageBanners-module_alert__O2lYb","systemIcon":"PageBanners-module_systemIcon__su3aG","alertIcon":"PageBanners-module_alertIcon__owy3V","alertTitle":"PageBanners-module_alertTitle__zeo3d","alertDismiss":"PageBanners-module_alertDismiss__2JI9V","content":"PageBanners-module_content__ZHLA9","title":"PageBanners-module_title__-53EA","detail":"PageBanners-module_detail__xgNJE","clamp":"PageBanners-module_clamp__iWIIp","alertLink":"PageBanners-module_alertLink__mxQM5","dismiss":"PageBanners-module_dismiss__aWRXw"};
|
|
1560
1560
|
|
|
1561
1561
|
const decodeEntities = (value) => {
|
|
1562
1562
|
if (typeof document === 'undefined')
|
|
@@ -1583,13 +1583,13 @@ const PageBanners = ({ systemBanners, alertBanners, className = '', }) => {
|
|
|
1583
1583
|
const visibleAlerts = alertBanners.filter((banner) => !dismissed.has(banner.id));
|
|
1584
1584
|
if (!visibleSystem.length && !visibleAlerts.length)
|
|
1585
1585
|
return null;
|
|
1586
|
-
return (jsxs("div", { className: [styles$
|
|
1587
|
-
const content = (jsxs("div", { className: styles$
|
|
1588
|
-
return (jsxs("div", { className: [styles$
|
|
1586
|
+
return (jsxs("div", { className: [styles$t.stack, className].filter(Boolean).join(' '), role: "region", "aria-label": "Page notices", children: [visibleSystem.map((banner) => (jsxs("div", { className: [styles$t.banner, styles$t.system].join(' '), role: "status", children: [jsx(InfoIcon$1, { className: styles$t.systemIcon, size: 20, "aria-hidden": "true" }), jsxs("div", { className: styles$t.content, children: [jsx("p", { className: styles$t.title, dangerouslySetInnerHTML: { __html: banner.html } }), banner.detailHtml && (jsx("p", { className: styles$t.detail, dangerouslySetInnerHTML: { __html: banner.detailHtml } }))] }), jsx("button", { type: "button", className: styles$t.dismiss, "aria-label": "Dismiss notice", onClick: () => dismiss(banner.id), children: jsx(CloseIcon, { size: 16 }) })] }, banner.id))), visibleAlerts.map((banner) => {
|
|
1587
|
+
const content = (jsxs("div", { className: styles$t.content, children: [jsx("p", { className: [styles$t.title, styles$t.alertTitle].join(' '), children: decodeEntities(banner.title) }), banner.body && jsx("p", { className: [styles$t.detail, styles$t.clamp].join(' '), children: decodeEntities(banner.body) })] }));
|
|
1588
|
+
return (jsxs("div", { className: [styles$t.banner, styles$t.alert].join(' '), role: "alert", children: [jsx(WarningIcon$1, { className: styles$t.alertIcon, size: 20, "aria-hidden": "true" }), banner.href ? (jsx("a", { href: banner.href, className: styles$t.alertLink, children: content })) : (content), jsx("button", { type: "button", className: [styles$t.dismiss, styles$t.alertDismiss].join(' '), "aria-label": "Dismiss alert", onClick: () => dismiss(banner.id), children: jsx(CloseIcon, { size: 16 }) })] }, banner.id));
|
|
1589
1589
|
})] }));
|
|
1590
1590
|
};
|
|
1591
1591
|
|
|
1592
|
-
var styles$
|
|
1592
|
+
var styles$s = {"panel":"PreferencesPanel-module_panel__xsxcw","loading":"PreferencesPanel-module_loading__GopYy","alert":"PreferencesPanel-module_alert__9yYz3","title":"PreferencesPanel-module_title__Z5dpP","grid":"PreferencesPanel-module_grid__e0urP","section":"PreferencesPanel-module_section__6cbAx","sectionHeader":"PreferencesPanel-module_sectionHeader__X6e5h","sectionIcon":"PreferencesPanel-module_sectionIcon__jVJwn","sectionTitle":"PreferencesPanel-module_sectionTitle__29M-O","fields":"PreferencesPanel-module_fields__rryQ3","field":"PreferencesPanel-module_field__W3Z9z","fieldLabel":"PreferencesPanel-module_fieldLabel__usgRa","fieldValue":"PreferencesPanel-module_fieldValue__AEJ1C","fieldInput":"PreferencesPanel-module_fieldInput__rS8OR","footer":"PreferencesPanel-module_footer__qTYqi"};
|
|
1593
1593
|
|
|
1594
1594
|
const PlaneIcon = () => (jsx("svg", { width: "20", height: "20", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: jsx("path", { d: "M21 16v-2l-8-5V3.5a1.5 1.5 0 0 0-3 0V9l-8 5v2l8-2.5V19l-2 1.5V22l3.5-1 3.5 1v-1.5L13 19v-5.5l8 2.5Z" }) }));
|
|
1595
1595
|
const BusIcon = () => (jsxs("svg", { width: "20", height: "20", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", children: [jsx("rect", { x: "4", y: "4", width: "16", height: "14", rx: "2" }), jsx("path", { d: "M8 6v6" }), jsx("path", { d: "M16 6v6" }), jsx("circle", { cx: "8", cy: "16", r: "1" }), jsx("circle", { cx: "16", cy: "16", r: "1" })] }));
|
|
@@ -1604,15 +1604,15 @@ const DEFAULT_ICONS = {
|
|
|
1604
1604
|
*/
|
|
1605
1605
|
const PreferencesPanel = ({ title, sections, alert, footer, isLoading = false, className = '', }) => {
|
|
1606
1606
|
const panelClasses = [
|
|
1607
|
-
styles$
|
|
1608
|
-
isLoading ? styles$
|
|
1607
|
+
styles$s.panel,
|
|
1608
|
+
isLoading ? styles$s.loading : '',
|
|
1609
1609
|
className,
|
|
1610
1610
|
].filter(Boolean).join(' ');
|
|
1611
|
-
return (jsxs("div", { className: panelClasses, children: [alert && (jsx("div", { className: styles$
|
|
1611
|
+
return (jsxs("div", { className: panelClasses, children: [alert && (jsx("div", { className: styles$s.alert, children: alert })), title && jsx("h2", { className: styles$s.title, children: title }), jsx("div", { className: styles$s.grid, children: sections.map((section, i) => (jsxs("div", { className: styles$s.section, children: [jsxs("div", { className: styles$s.sectionHeader, children: [(section.icon || DEFAULT_ICONS[section.title.toLowerCase()]) && (jsx("span", { className: styles$s.sectionIcon, children: section.icon || DEFAULT_ICONS[section.title.toLowerCase()] })), jsx("h3", { className: styles$s.sectionTitle, children: section.title })] }), jsx("div", { className: styles$s.fields, children: section.fields.map((field, j) => (jsxs("div", { className: styles$s.field, children: [jsx("label", { className: styles$s.fieldLabel, children: field.label }), field.input ? (jsx("div", { className: styles$s.fieldInput, children: field.input })) : (jsx("div", { className: styles$s.fieldValue, children: field.value || '—' }))] }, j))) })] }, i))) }), footer && (jsx("div", { className: styles$s.footer, children: footer }))] }));
|
|
1612
1612
|
};
|
|
1613
1613
|
PreferencesPanel.displayName = 'PreferencesPanel';
|
|
1614
1614
|
|
|
1615
|
-
var styles$
|
|
1615
|
+
var styles$r = {"summary":"RequestSummary-module_summary__nxews","title":"RequestSummary-module_title__NAq53","submissionInfo":"RequestSummary-module_submissionInfo__dwkaf","label":"RequestSummary-module_label__pGo-5","value":"RequestSummary-module_value__F8m9g","sections":"RequestSummary-module_sections__uWXtM","section":"RequestSummary-module_section__TlxbY","sectionTitle":"RequestSummary-module_sectionTitle__iMPB2","segment":"RequestSummary-module_segment__xq-Lp","segmentTitle":"RequestSummary-module_segmentTitle__ey5-f","row":"RequestSummary-module_row__tfJzQ","empty":"RequestSummary-module_empty__fzxmd"};
|
|
1616
1616
|
|
|
1617
1617
|
/**
|
|
1618
1618
|
* SummaryItem component displays a single label-value pair.
|
|
@@ -1621,7 +1621,7 @@ const SummaryItemRow = ({ item, value }) => {
|
|
|
1621
1621
|
if (!value)
|
|
1622
1622
|
return null;
|
|
1623
1623
|
const formattedValue = item.format ? item.format(value) : String(value);
|
|
1624
|
-
return (jsxs("div", { className: styles$
|
|
1624
|
+
return (jsxs("div", { className: styles$r.row, children: [jsx("span", { className: styles$r.label, children: item.label }), jsx("span", { className: styles$r.value, children: formattedValue })] }));
|
|
1625
1625
|
};
|
|
1626
1626
|
/**
|
|
1627
1627
|
* SummarySection component for a group of related summary items.
|
|
@@ -1632,7 +1632,7 @@ const SummarySection = ({ section, values }) => {
|
|
|
1632
1632
|
const hasSegments = section.segments?.some(seg => seg.items.some(item => values[`${section.key}_${seg.label}_${item.label}`] || values[item.label]));
|
|
1633
1633
|
if (!hasItems && !hasSegments)
|
|
1634
1634
|
return null;
|
|
1635
|
-
return (jsxs("div", { className: styles$
|
|
1635
|
+
return (jsxs("div", { className: styles$r.section, children: [jsx("h3", { className: styles$r.sectionTitle, children: section.title }), section.items?.map((item, i) => (jsx(SummaryItemRow, { item: item, value: values[item.label] || values[`${section.key}_${item.label}`] }, i))), section.segments?.map((segment, i) => (jsxs("div", { className: styles$r.segment, children: [jsx("h4", { className: styles$r.segmentTitle, children: segment.label }), segment.items.map((item, j) => (jsx(SummaryItemRow, { item: item, value: values[`${section.key}_${segment.label}_${item.label}`] || values[item.label] }, j)))] }, i)))] }));
|
|
1636
1636
|
};
|
|
1637
1637
|
/**
|
|
1638
1638
|
* RequestSummary component for displaying a summary of travel request form data.
|
|
@@ -1640,18 +1640,18 @@ const SummarySection = ({ section, values }) => {
|
|
|
1640
1640
|
*/
|
|
1641
1641
|
const RequestSummary$1 = ({ sections, values, enabledSections = {}, submissionInfo, className, title = 'Request Summary', }) => {
|
|
1642
1642
|
const visibleSections = sections.filter(section => enabledSections[section.key] !== false);
|
|
1643
|
-
return (jsxs("div", { className: `${styles$
|
|
1643
|
+
return (jsxs("div", { className: `${styles$r.summary} ${className || ''}`, children: [jsx("h2", { className: styles$r.title, children: title }), submissionInfo && (jsxs("div", { className: styles$r.submissionInfo, children: [jsx("span", { className: styles$r.label, children: "Submitted by" }), jsx("span", { className: styles$r.value, children: submissionInfo.submittedBy }), jsx("span", { className: styles$r.label, children: "on" }), jsx("span", { className: styles$r.value, children: submissionInfo.submittedOn })] })), jsx("div", { className: styles$r.sections, children: visibleSections.map((section) => (jsx(SummarySection, { section: section, values: values }, section.key))) }), visibleSections.length === 0 && (jsx("p", { className: styles$r.empty, children: "No services selected" }))] }));
|
|
1644
1644
|
};
|
|
1645
1645
|
RequestSummary$1.displayName = 'RequestSummary';
|
|
1646
1646
|
|
|
1647
|
-
var styles$
|
|
1647
|
+
var styles$q = {"layout":"RequestFormLayout-module_layout__R-vaM","header":"RequestFormLayout-module_header__705In","headerContent":"RequestFormLayout-module_headerContent__Uu0br","headerTitle":"RequestFormLayout-module_headerTitle__W-fub","pagination":"RequestFormLayout-module_pagination__hTpNr","separator":"RequestFormLayout-module_separator__BgEsp","eventName":"RequestFormLayout-module_eventName__1zpgS","headerRight":"RequestFormLayout-module_headerRight__VjjY3","body":"RequestFormLayout-module_body__RBH8O","sidebar":"RequestFormLayout-module_sidebar__Ozr7m","showOnMobile":"RequestFormLayout-module_showOnMobile__kyyER","sidebarContent":"RequestFormLayout-module_sidebarContent__IdoMX","main":"RequestFormLayout-module_main__132ss","mainContent":"RequestFormLayout-module_mainContent__vnp1R","summarySidebar":"RequestFormLayout-module_summarySidebar__Vfg-z","summaryContent":"RequestFormLayout-module_summaryContent__Oppnd","footer":"RequestFormLayout-module_footer__yxDM5","footerContent":"RequestFormLayout-module_footerContent__GmTkE","button":"RequestFormLayout-module_button__-iWUv","primary":"RequestFormLayout-module_primary__cs2Fb","secondary":"RequestFormLayout-module_secondary__9WNRX"};
|
|
1648
1648
|
|
|
1649
1649
|
/**
|
|
1650
1650
|
* RequestFormHeader component for the fixed header in travel request forms.
|
|
1651
1651
|
*/
|
|
1652
1652
|
const RequestFormHeader = ({ title, currentPage, totalPages, eventName, rightContent, className, }) => {
|
|
1653
1653
|
const showPagination = currentPage !== undefined && totalPages !== undefined && totalPages > 1;
|
|
1654
|
-
return (jsx("header", { className: `${styles$
|
|
1654
|
+
return (jsx("header", { className: `${styles$q.header} ${className || ''}`, children: jsxs("div", { className: styles$q.headerContent, children: [jsxs("h1", { className: styles$q.headerTitle, children: [title, showPagination && (jsxs("span", { className: styles$q.pagination, children: ["(", currentPage, "/", totalPages, ")"] })), eventName && (jsxs(Fragment, { children: [jsx("span", { className: styles$q.separator, children: "\u2013" }), jsx("span", { className: styles$q.eventName, children: eventName })] }))] }), rightContent && jsx("div", { className: styles$q.headerRight, children: rightContent })] }) }));
|
|
1655
1655
|
};
|
|
1656
1656
|
/**
|
|
1657
1657
|
* RequestFormFooter component for the fixed footer with navigation buttons.
|
|
@@ -1659,20 +1659,20 @@ const RequestFormHeader = ({ title, currentPage, totalPages, eventName, rightCon
|
|
|
1659
1659
|
const RequestFormFooter = ({ onPrevious, onNext, isFirstPage = false, isLastPage = false, isSubmitting = false, previousText, nextText, className, }) => {
|
|
1660
1660
|
const prevLabel = previousText || (isFirstPage ? 'Cancel' : 'Previous');
|
|
1661
1661
|
const nextLabel = nextText || (isLastPage ? 'Submit' : 'Next');
|
|
1662
|
-
return (jsx("footer", { className: `${styles$
|
|
1662
|
+
return (jsx("footer", { className: `${styles$q.footer} ${className || ''}`, children: jsxs("div", { className: styles$q.footerContent, children: [jsx("button", { type: "button", className: `${styles$q.button} ${styles$q.secondary}`, onClick: onPrevious, disabled: isSubmitting, children: prevLabel }), jsx("button", { type: "button", className: `${styles$q.button} ${styles$q.primary}`, onClick: onNext, disabled: isSubmitting, children: isSubmitting ? 'Submitting...' : nextLabel })] }) }));
|
|
1663
1663
|
};
|
|
1664
1664
|
/**
|
|
1665
1665
|
* RequestFormLayout organism for travel request forms.
|
|
1666
1666
|
* Provides a three-column layout with fixed header and footer.
|
|
1667
1667
|
*/
|
|
1668
1668
|
const RequestFormLayout = ({ header, sidebar, children, summary, footer, className, showSidebarOnMobile = false, }) => {
|
|
1669
|
-
return (jsxs("div", { className: `${styles$
|
|
1669
|
+
return (jsxs("div", { className: `${styles$q.layout} ${className || ''}`, children: [header, jsxs("div", { className: styles$q.body, children: [sidebar && (jsx("aside", { className: `${styles$q.sidebar} ${showSidebarOnMobile ? styles$q.showOnMobile : ''}`, children: jsx("div", { className: styles$q.sidebarContent, children: sidebar }) })), jsx("main", { className: styles$q.main, children: jsx("div", { className: styles$q.mainContent, children: children }) }), summary && (jsx("aside", { className: styles$q.summarySidebar, children: jsx("div", { className: styles$q.summaryContent, children: summary }) }))] }), footer] }));
|
|
1670
1670
|
};
|
|
1671
1671
|
RequestFormLayout.displayName = 'RequestFormLayout';
|
|
1672
1672
|
RequestFormHeader.displayName = 'RequestFormHeader';
|
|
1673
1673
|
RequestFormFooter.displayName = 'RequestFormFooter';
|
|
1674
1674
|
|
|
1675
|
-
var styles$
|
|
1675
|
+
var styles$p = {"wrapper":"Table-module_wrapper__1klo5","table":"Table-module_table__fkuUB","header":"Table-module_header__vRy6j","headerCell":"Table-module_headerCell__2KzYn","headerContent":"Table-module_headerContent__HPl8-","sortable":"Table-module_sortable__NiS6E","sortIcon":"Table-module_sortIcon__Fy6z7","body":"Table-module_body__Wt52U","row":"Table-module_row__4GEgX","cell":"Table-module_cell__Xr-7H","alignLeft":"Table-module_alignLeft__FtI9E","alignCenter":"Table-module_alignCenter__p8Tr8","alignRight":"Table-module_alignRight__Ca7Yr","bordered":"Table-module_bordered__9bM3L","striped":"Table-module_striped__6TMF-","hoverable":"Table-module_hoverable__KN5Fp","compact":"Table-module_compact__opzS-","clickable":"Table-module_clickable__2ummV","loading":"Table-module_loading__tFELE","empty":"Table-module_empty__urRiw","pulse":"Table-module_pulse__t32v9"};
|
|
1676
1676
|
|
|
1677
1677
|
const Table = ({ columns, data, rowKey = 'id', bordered = false, striped = false, hoverable = true, compact = false, loading = false, emptyMessage = 'No data available', onRowClick, className = '', }) => {
|
|
1678
1678
|
const [sortColumn, setSortColumn] = useState(null);
|
|
@@ -1710,12 +1710,12 @@ const Table = ({ columns, data, rowKey = 'id', bordered = false, striped = false
|
|
|
1710
1710
|
}
|
|
1711
1711
|
return row[rowKey] ?? index;
|
|
1712
1712
|
};
|
|
1713
|
-
return (jsx("div", { className: `${styles$
|
|
1713
|
+
return (jsx("div", { className: `${styles$p.wrapper} ${className}`, children: jsxs("table", { className: `${styles$p.table} ${bordered ? styles$p.bordered : ''} ${striped ? styles$p.striped : ''} ${hoverable ? styles$p.hoverable : ''} ${compact ? styles$p.compact : ''}`, children: [jsx("thead", { className: styles$p.header, children: jsx("tr", { children: columns.map((column) => (jsx("th", { className: `${styles$p.headerCell} ${column.sortable ? styles$p.sortable : ''} ${styles$p[`align${(column.align || 'left').charAt(0).toUpperCase()}${(column.align || 'left').slice(1)}`]}`, style: column.width ? { width: column.width } : undefined, onClick: () => handleSort(column), children: jsxs("span", { className: styles$p.headerContent, children: [column.label, column.sortable && (jsx("span", { className: styles$p.sortIcon, children: sortColumn === column.key ? (sortDirection === 'asc' ? '↑' : '↓') : ('↕') }))] }) }, column.key))) }) }), jsx("tbody", { className: styles$p.body, children: loading ? (jsx("tr", { children: jsx("td", { colSpan: columns.length, className: styles$p.loading, children: "Loading..." }) })) : sortedData.length === 0 ? (jsx("tr", { children: jsx("td", { colSpan: columns.length, className: styles$p.empty, children: emptyMessage }) })) : (sortedData.map((row, rowIndex) => (jsx("tr", { className: `${styles$p.row} ${onRowClick ? styles$p.clickable : ''}`, onClick: () => onRowClick?.(row, rowIndex), children: columns.map((column) => (jsx("td", { className: `${styles$p.cell} ${styles$p[`align${(column.align || 'left').charAt(0).toUpperCase()}${(column.align || 'left').slice(1)}`]}`, children: column.render
|
|
1714
1714
|
? column.render(row[column.key], row, rowIndex)
|
|
1715
1715
|
: row[column.key] }, column.key))) }, getRowKey(row, rowIndex))))) })] }) }));
|
|
1716
1716
|
};
|
|
1717
1717
|
|
|
1718
|
-
var styles$
|
|
1718
|
+
var styles$o = {"card":"TeamCard-module_card__R2u4q","header":"TeamCard-module_header__XXRUp","icon":"TeamCard-module_icon__l2Go2","title":"TeamCard-module_title__llL8V","body":"TeamCard-module_body__OoVMW","tabs":"TeamCard-module_tabs__SJ7t-","tab":"TeamCard-module_tab__Q5j3C","tabActive":"TeamCard-module_tabActive__dUPwX","list":"TeamCard-module_list__a734u","teamItem":"TeamCard-module_teamItem__OYVIK","teamCode":"TeamCard-module_teamCode__BHB63","teamName":"TeamCard-module_teamName__-Bds2","chevron":"TeamCard-module_chevron__zBxM6","empty":"TeamCard-module_empty__8b5hb"};
|
|
1719
1719
|
|
|
1720
1720
|
const TEAM_GROUPS = [
|
|
1721
1721
|
{ label: 'All', key: undefined },
|
|
@@ -1749,14 +1749,14 @@ const TeamCard = ({ title = 'Administer Teams', icon, teams, onTeamSelect, class
|
|
|
1749
1749
|
return teams.filter(team => team.category === activeTab);
|
|
1750
1750
|
}, [teams, activeTab]);
|
|
1751
1751
|
const cardClasses = [
|
|
1752
|
-
styles$
|
|
1752
|
+
styles$o.card,
|
|
1753
1753
|
className,
|
|
1754
1754
|
].filter(Boolean).join(' ');
|
|
1755
|
-
return (jsxs("div", { className: cardClasses, "data-test": "team-card", children: [jsxs("div", { className: styles$
|
|
1755
|
+
return (jsxs("div", { className: cardClasses, "data-test": "team-card", children: [jsxs("div", { className: styles$o.header, children: [jsx("span", { className: styles$o.icon, children: icon || jsx(UsersIcon, {}) }), jsx("h3", { className: styles$o.title, children: title })] }), jsxs("div", { className: styles$o.body, children: [jsx("div", { className: styles$o.tabs, children: TEAM_GROUPS.map(({ label, key }) => (jsx("button", { type: "button", onClick: () => setActiveTab(key), className: `${styles$o.tab} ${activeTab === key ? styles$o.tabActive : ''}`, "data-test": `team-card-filter-${key ?? 'all'}`, children: label }, label))) }), jsxs("div", { className: styles$o.list, children: [filteredTeams.map((team) => (jsxs("button", { type: "button", className: styles$o.teamItem, "data-test": `team-card-team-${team.id}`, onClick: () => onTeamSelect?.(team), children: [jsx("span", { className: styles$o.teamCode, style: { backgroundColor: getTeamColor(team.code) }, children: team.code }), jsx("span", { className: styles$o.teamName, children: team.description }), jsx("span", { className: styles$o.chevron, children: jsx(ChevronRightIcon, {}) })] }, team.id))), filteredTeams.length === 0 && (jsx("div", { className: styles$o.empty, children: "No teams found" }))] })] })] }));
|
|
1756
1756
|
};
|
|
1757
1757
|
TeamCard.displayName = 'TeamCard';
|
|
1758
1758
|
|
|
1759
|
-
var styles$
|
|
1759
|
+
var styles$n = {"panel":"TeamContactsPanel-module_panel__ox2ws","contactsModule":"TeamContactsPanel-module_contactsModule__grnnt","moduleBody":"TeamContactsPanel-module_moduleBody__9uTOW","moduleTitle":"TeamContactsPanel-module_moduleTitle__fuXRZ","infoButton":"TeamContactsPanel-module_infoButton__gq-T7","contactsGrid":"TeamContactsPanel-module_contactsGrid__bwue-","primaryGrid":"TeamContactsPanel-module_primaryGrid__ToUU1","verticalDivider":"TeamContactsPanel-module_verticalDivider__EwXj7","ccGrid":"TeamContactsPanel-module_ccGrid__Muf5N","picker":"TeamContactsPanel-module_picker__dIkEm","fieldLabel":"TeamContactsPanel-module_fieldLabel__1RMEZ","contactSegment":"TeamContactsPanel-module_contactSegment__FaK2K","contactAvatar":"TeamContactsPanel-module_contactAvatar__2DHmg","optionAvatar":"TeamContactsPanel-module_optionAvatar__jaIeL","contactDetails":"TeamContactsPanel-module_contactDetails__ob0ad","compactSegment":"TeamContactsPanel-module_compactSegment__B7CKZ","contactTrigger":"TeamContactsPanel-module_contactTrigger__-3jxx","emptyContact":"TeamContactsPanel-module_emptyContact__JnYCr","inactiveContact":"TeamContactsPanel-module_inactiveContact__uY-iK","contactTitle":"TeamContactsPanel-module_contactTitle__bl6C5","contactLink":"TeamContactsPanel-module_contactLink__TAnpf","contactMenu":"TeamContactsPanel-module_contactMenu__W6fQ-","compactMenu":"TeamContactsPanel-module_compactMenu__jCBcm","searchRow":"TeamContactsPanel-module_searchRow__kn7Nk","menuDivider":"TeamContactsPanel-module_menuDivider__7nn8t","contactOptions":"TeamContactsPanel-module_contactOptions__vcKoY","contactOption":"TeamContactsPanel-module_contactOption__ZfFUU","clearContact":"TeamContactsPanel-module_clearContact__C3SNA","clearIcon":"TeamContactsPanel-module_clearIcon__oEKaE","emptyOptions":"TeamContactsPanel-module_emptyOptions__IM68-"};
|
|
1760
1760
|
|
|
1761
1761
|
const CONTACTS_NOTE = (jsxs(Fragment, { children: [jsx("strong", { children: "PLEASE NOTE:" }), " Primary and secondary contacts listed below will receive virtual invoices on all team travel trips. They also receive automated team travel email reminders. The primary contact receives team travel text alerts during travel. All CC contacts listed below will receive virtual invoices on all travel trips including individual travel."] }));
|
|
1762
1762
|
const CONTACTS_TOOLTIP = 'Only contacts listed in the School Contacts are available to select as Team Contacts. Adding a contact to this team will add them to the User Contacts as well, but they can be removed if desired.';
|
|
@@ -1791,7 +1791,7 @@ const ContactPicker = ({ title, contacts, selectedId, onSelect, allowNone = true
|
|
|
1791
1791
|
setSearch('');
|
|
1792
1792
|
}
|
|
1793
1793
|
};
|
|
1794
|
-
return (jsxs("div", { className: styles$
|
|
1794
|
+
return (jsxs("div", { className: styles$n.picker, ref: containerRef, "data-test": dataTestId, children: [jsx("div", { className: styles$n.fieldLabel, children: title }), jsxs("div", { className: [styles$n.contactSegment, compact ? styles$n.compactSegment : ''].filter(Boolean).join(' '), children: [!compact && selected && jsx(Avatar, { className: styles$n.contactAvatar, name: selected.name, size: "sm" }), jsxs("div", { className: styles$n.contactDetails, children: [jsxs("button", { type: "button", className: [styles$n.contactTrigger, !selected ? styles$n.emptyContact : '', selected?.active === false ? styles$n.inactiveContact : ''].filter(Boolean).join(' '), disabled: disabled || pending, "data-test": `${dataTestId}-trigger`, "aria-expanded": open, "aria-haspopup": "listbox", "aria-busy": pending, "aria-label": `${title}: ${selected?.name ?? `Select ${title}`}`, onClick: () => setOpen((current) => !current), children: [jsx("span", { children: selected?.name ?? `Select ${title}` }), selected?.active === false && (jsx(Tooltip, { content: "A contact displayed in red is no longer an active portal user and must be replaced by an active user to ensure the accurate delivery of documents and notifications.", position: "right", variant: "error", delay: 0, children: jsx(WarningIcon$1, { size: 16, "aria-label": "Inactive portal user" }) })), pending ? jsx(Spinner, { size: "sm", label: `Updating ${title}` }) : open ? jsx(ChevronUpIcon, { size: 16 }) : jsx(ChevronDownIcon$1, { size: 16 })] }), !compact && selected?.title && jsx("span", { className: styles$n.contactTitle, children: selected.title }), !compact && selected?.phone && jsxs("a", { href: `tel:${selected.phone}`, className: styles$n.contactLink, children: [jsx(PhoneIcon, { size: 20 }), " ", selected.phone] }), !compact && selected?.email && jsxs("a", { href: `mailto:${selected.email}`, className: styles$n.contactLink, children: [jsx(MailIcon, { size: 20 }), " ", selected.email] })] })] }), open && (jsxs("div", { className: [styles$n.contactMenu, compact ? styles$n.compactMenu : ''].filter(Boolean).join(' '), role: "listbox", "aria-label": `${title} options`, children: [jsx("div", { className: styles$n.searchRow, children: jsx(Input, { size: "xs", fullWidth: true, autoFocus: true, value: search, placeholder: "Search contacts", "aria-label": `Search ${title}`, "data-test": `${dataTestId}-search`, leftIcon: jsx(SearchIcon$1, { size: 15 }), onChange: (event) => setSearch(event.target.value) }) }), jsx("div", { className: styles$n.menuDivider }), jsxs("div", { className: styles$n.contactOptions, children: [allowNone && selected && (jsxs("button", { type: "button", className: styles$n.clearContact, "data-test": `${dataTestId}-clear`, disabled: selecting, onClick: () => void select(undefined), children: [jsx("span", { className: styles$n.clearIcon, children: jsx(TrashIcon$2, { size: 16 }) }), jsxs("span", { children: ["Clear ", title] })] })), filteredContacts.map((contact) => (jsxs("button", { type: "button", role: "option", "aria-selected": false, className: styles$n.contactOption, "data-test": `${dataTestId}-option-${contact.id}`, disabled: selecting, onClick: () => void select(contact.id), children: [jsx(Avatar, { className: styles$n.optionAvatar, name: contact.name, size: "sm" }), jsxs("span", { children: [jsx("strong", { children: contact.name }), contact.title && jsx("small", { children: contact.title })] })] }, contact.id))), !filteredContacts.length && jsx("div", { className: styles$n.emptyOptions, children: "No matching contacts" })] })] }))] }));
|
|
1795
1795
|
};
|
|
1796
1796
|
const TeamContactsPanel = ({ contacts, value, onChange, disabled = false, loading = {}, dataTestId = 'team-contacts', className = '', }) => {
|
|
1797
1797
|
const ccContactIds = Array.from({ length: 4 }, (_, index) => value.ccContactIds?.[index]);
|
|
@@ -1800,23 +1800,23 @@ const TeamContactsPanel = ({ contacts, value, onChange, disabled = false, loadin
|
|
|
1800
1800
|
next[index] = id;
|
|
1801
1801
|
onChange?.({ ...value, ccContactIds: next });
|
|
1802
1802
|
};
|
|
1803
|
-
return (jsxs("div", { className: [styles$
|
|
1803
|
+
return (jsxs("div", { className: [styles$n.panel, className].filter(Boolean).join(' '), "data-test": dataTestId, children: [jsx(Alert, { variant: "warning", children: CONTACTS_NOTE }), jsx(Module, { title: (jsxs("span", { className: styles$n.moduleTitle, children: [jsx("span", { children: "Team Contacts" }), jsx(Tooltip, { content: CONTACTS_TOOLTIP, position: "bottom", variant: "primary", delay: 0, children: jsx("button", { type: "button", className: styles$n.infoButton, "aria-label": "Team contacts information", children: jsx(InfoIcon$1, { size: 16 }) }) })] })), useToggle: false, className: styles$n.contactsModule, bodyClassName: styles$n.moduleBody, children: jsxs("div", { className: styles$n.contactsGrid, children: [jsxs("div", { className: styles$n.primaryGrid, children: [jsx(ContactPicker, { title: "Primary Contact", contacts: contacts, selectedId: value.primaryContactId, allowNone: false, disabled: disabled, loading: loading.primary, dataTestId: `${dataTestId}-primary`, onSelect: (primaryContactId) => onChange?.({ ...value, primaryContactId }) }), jsx("div", { className: styles$n.verticalDivider }), jsx(ContactPicker, { title: "Secondary Contact", contacts: contacts, selectedId: value.secondaryContactId, disabled: disabled, loading: loading.secondary, dataTestId: `${dataTestId}-secondary`, onSelect: (secondaryContactId) => onChange?.({ ...value, secondaryContactId }) })] }), jsx("div", { className: styles$n.verticalDivider }), jsx("div", { className: styles$n.ccGrid, children: ccContactIds.map((contactId, index) => (jsx(ContactPicker, { title: `CC Contact ${index + 1}`, contacts: contacts, selectedId: contactId, compact: true, disabled: disabled, loading: loading.cc?.[index], dataTestId: `${dataTestId}-cc-${index + 1}`, onSelect: (id) => updateCC(index, id) }, index))) })] }) })] }));
|
|
1804
1804
|
};
|
|
1805
1805
|
TeamContactsPanel.displayName = 'TeamContactsPanel';
|
|
1806
1806
|
|
|
1807
|
-
var styles$
|
|
1807
|
+
var styles$m = {"actions":"TeamScheduleActions-module_actions__OvuON","primaryRow":"TeamScheduleActions-module_primaryRow__8rwhE","tripCount":"TeamScheduleActions-module_tripCount__4axn4","seasonNavigator":"TeamScheduleActions-module_seasonNavigator__jmqeE","seasonLabel":"TeamScheduleActions-module_seasonLabel__8MtKK","secondaryRow":"TeamScheduleActions-module_secondaryRow__We2n9"};
|
|
1808
1808
|
|
|
1809
1809
|
/** Exact presentational counterpart of Hub's Team Schedule action controls. */
|
|
1810
|
-
const TeamScheduleActions = ({ isCompactView, tripCount, seasonLabel, seasonValue, seasonOptions = [], previousSeasonDisabled = false, exportDisabled = false, exporting = false, groupTravelDisabled = false, mergeDisabled = false, merging = false, onViewSchedule, onBack, onPreviousSeason, onNextSeason, onSeasonChange, onExport, onGroupTravelRequest, onMergeEvents, className = '', }) => (jsxs("div", { className: [styles$
|
|
1810
|
+
const TeamScheduleActions = ({ isCompactView, tripCount, seasonLabel, seasonValue, seasonOptions = [], previousSeasonDisabled = false, exportDisabled = false, exporting = false, groupTravelDisabled = false, mergeDisabled = false, merging = false, onViewSchedule, onBack, onPreviousSeason, onNextSeason, onSeasonChange, onExport, onGroupTravelRequest, onMergeEvents, className = '', }) => (jsxs("div", { className: [styles$m.actions, className].filter(Boolean).join(' '), "data-test": "team-schedule-actions", children: [jsxs("div", { className: styles$m.primaryRow, children: [!isCompactView ? (jsx(Button, { "data-test": "team-schedule-view-edit", size: "sm", onClick: onViewSchedule, children: "View/Edit Schedule" })) : (jsx(Button, { "data-test": "team-schedule-back", size: "sm", onClick: onBack, leftIcon: jsx(ChevronLeftIcon, { size: 14 }), children: "Back" })), jsxs("div", { className: styles$m.seasonNavigator, children: [jsx(Button, { "data-test": "team-schedule-previous-season", variant: "secondary", size: "sm", square: true, "aria-label": "Previous Season", disabled: previousSeasonDisabled, onClick: onPreviousSeason, children: jsx(ChevronLeftIcon, { size: 18 }) }), jsxs("div", { className: styles$m.seasonLabel, children: [jsx(Button, { variant: "secondary", size: "sm", children: seasonLabel }), !!seasonOptions.length && (jsx("select", { "data-test": "team-schedule-season", "aria-label": "Season", value: seasonValue, onChange: (event) => onSeasonChange?.(event.target.value), children: seasonOptions.map((option) => jsx("option", { value: option.value, children: option.label }, option.value)) }))] }), jsx(Button, { "data-test": "team-schedule-next-season", variant: "secondary", size: "sm", square: true, "aria-label": "Next Season", onClick: onNextSeason, children: jsx(ChevronRightIcon$1, { size: 18 }) })] }), isCompactView && jsx(Button, { "data-test": "team-schedule-export", variant: "outline", size: "sm", loading: exporting, disabled: exportDisabled, rightIcon: jsx(ArrowUpRightIcon, { size: 14 }), onClick: onExport, children: "Export XLS" }), jsxs("span", { className: styles$m.tripCount, "data-test": "team-schedule-trip-count", children: [tripCount, " trips displayed"] })] }), isCompactView && (jsxs("div", { className: styles$m.secondaryRow, children: [jsx(Button, { "data-test": "team-schedule-group-travel-request", variant: "outline", size: "sm", disabled: groupTravelDisabled, onClick: onGroupTravelRequest, children: "Group Travel Request" }), jsx(Button, { "data-test": "team-schedule-merge-events", variant: "outline", size: "sm", disabled: mergeDisabled, loading: merging, onClick: onMergeEvents, children: "Merge Events" })] }))] }));
|
|
1811
1811
|
|
|
1812
|
-
var styles$
|
|
1812
|
+
var styles$l = {"headers":"TeamScheduleCompactTable-module_headers__FVr2C","tripHeader":"TeamScheduleCompactTable-module_tripHeader__9vr2-","eventHeader":"TeamScheduleCompactTable-module_eventHeader__6gfwo","table":"TeamScheduleCompactTable-module_table__MdE3o","row":"TeamScheduleCompactTable-module_row__Rt0YC","trip":"TeamScheduleCompactTable-module_trip__oAUEQ","events":"TeamScheduleCompactTable-module_events__EwJi9","empty":"TeamScheduleCompactTable-module_empty__1u5HA","addRow":"TeamScheduleCompactTable-module_addRow__ejqSf"};
|
|
1813
1813
|
|
|
1814
1814
|
const DEFAULT_TRIP_HEADERS = ['', 'GTR', 'Trvl Start', 'Trvl End', 'Trip Name', 'Services', ''];
|
|
1815
1815
|
const DEFAULT_EVENT_HEADERS = ['', 'Event Date', 'Opponent/Host', 'Event Title', 'Hm/Awy', ''];
|
|
1816
1816
|
/** Hub's two-panel compact Team Schedule shell. Editable rows remain injectable. */
|
|
1817
|
-
const TeamScheduleCompactTable = ({ rows, tripHeaders = DEFAULT_TRIP_HEADERS, eventHeaders = DEFAULT_EVENT_HEADERS, onAddEvent, addEventDisabled = false, className = '', }) => (jsxs("div", { className: [styles$
|
|
1817
|
+
const TeamScheduleCompactTable = ({ rows, tripHeaders = DEFAULT_TRIP_HEADERS, eventHeaders = DEFAULT_EVENT_HEADERS, onAddEvent, addEventDisabled = false, className = '', }) => (jsxs("div", { className: [styles$l.schedule, className].filter(Boolean).join(' '), "data-test": "team-schedule-editor", children: [jsxs("div", { className: styles$l.headers, children: [jsx("div", { className: styles$l.tripHeader, children: tripHeaders.map((header, index) => jsx("div", { children: header }, index)) }), jsx("div", { className: styles$l.eventHeader, children: eventHeaders.map((header, index) => jsx("div", { children: header }, index)) })] }), jsx("div", { className: styles$l.table, children: !rows.length ? jsx("div", { className: styles$l.empty, "data-test": "team-schedule-empty", children: "No data available." }) : rows.map((row) => (jsxs("div", { className: styles$l.row, children: [jsx("div", { className: styles$l.trip, children: row.trip }), jsx("div", { className: styles$l.events, children: row.events })] }, row.id))) }), jsx("div", { className: styles$l.addRow, children: jsxs("button", { type: "button", disabled: addEventDisabled, onClick: onAddEvent, "data-test": "team-schedule-add-event", children: ["Add Event ", jsx(PlusIcon$2, { size: 16 })] }) })] }));
|
|
1818
1818
|
|
|
1819
|
-
var styles$
|
|
1819
|
+
var styles$k = {"table":"TeamScheduleExpandedTable-module_table__hmnHI","header":"TeamScheduleExpandedTable-module_header__7IWV-","row":"TeamScheduleExpandedTable-module_row__9MyHH","body":"TeamScheduleExpandedTable-module_body__NsvB3","cell":"TeamScheduleExpandedTable-module_cell__kgawH","tripLink":"TeamScheduleExpandedTable-module_tripLink__lYoi8","tripSummary":"TeamScheduleExpandedTable-module_tripSummary__XHSok","dueDates":"TeamScheduleExpandedTable-module_dueDates__vpCRG","dueDatesLabel":"TeamScheduleExpandedTable-module_dueDatesLabel__YwM9s","dueDate":"TeamScheduleExpandedTable-module_dueDate__8exi9","mobileLabel":"TeamScheduleExpandedTable-module_mobileLabel__J6apm","empty":"TeamScheduleExpandedTable-module_empty__d9Afo"};
|
|
1820
1820
|
|
|
1821
1821
|
const parseLocalDate = (value) => {
|
|
1822
1822
|
if (!value)
|
|
@@ -1843,6 +1843,11 @@ const formatTeamScheduleTravelDates = (startValue, endValue) => {
|
|
|
1843
1843
|
return `${formatDate$1(start)} - ${formatDate$1(end)}`;
|
|
1844
1844
|
return `${formatDate$1(start, false)} - ${end.getDate()}, ${end.getFullYear()}`;
|
|
1845
1845
|
};
|
|
1846
|
+
const formatTeamScheduleDueDate = (value) => {
|
|
1847
|
+
const date = parseLocalDate(value);
|
|
1848
|
+
return date ? date.toLocaleDateString('en-US', { month: 'long', day: 'numeric', year: 'numeric' }) : value;
|
|
1849
|
+
};
|
|
1850
|
+
const TripSummary = ({ row, onTripClick }) => (jsxs("div", { className: styles$k.tripSummary, children: [jsx("button", { type: "button", className: styles$k.tripLink, "data-test": `team-schedule-trip-${row.masterTripGUID}`, onClick: () => onTripClick?.(row), children: row.tripName }), !!row.dueDates?.length && (jsxs("div", { className: styles$k.dueDates, "data-test": `team-schedule-due-dates-${row.masterTripGUID}`, "aria-label": `Due dates for ${row.tripName}`, children: [jsx("span", { className: styles$k.dueDatesLabel, children: "Due Dates" }), row.dueDates.map((dueDate, index) => (jsxs("div", { className: styles$k.dueDate, "data-test": `team-schedule-due-date-${dueDate.id ?? index}`, children: [jsx("span", { children: dueDate.title }), jsx("time", { dateTime: dueDate.date, children: formatTeamScheduleDueDate(dueDate.date) })] }, dueDate.id ?? `${dueDate.title}-${dueDate.date}`)))] }))] }));
|
|
1846
1851
|
const RunningIcon = () => (jsxs("svg", { viewBox: "0 0 32 32", width: "16", height: "16", fill: "currentColor", "aria-hidden": "true", children: [jsx("circle", { cx: "21", cy: "5", r: "3" }), jsx("path", { d: "m18.5 9.3-4.2 4.2-4.1-2.1-1.4 2.8 5.9 3 3.3-3.2 2.3 5.2-5.2 3.2 1.7 2.6 7.4-4.6-3.3-7.2 2.4-2.4 2.1 3.1 2.6-1.8-4.2-6.4zM10 18.8 5.6 26H9l4-6.2z" })] }));
|
|
1847
1852
|
const GroundIcon = () => (jsxs("svg", { viewBox: "0 0 24 24", width: "16", height: "16", fill: "none", stroke: "currentColor", strokeWidth: "1.8", "aria-hidden": "true", children: [jsx("rect", { x: "4", y: "3", width: "16", height: "16", rx: "2" }), jsx("path", { d: "M4 13h16M8 7h3m2 0h3M7 19v2m10-2v2" })] }));
|
|
1848
1853
|
const headers = [
|
|
@@ -1870,20 +1875,20 @@ const TeamScheduleExpandedTable = ({ rows, teamCode, onTripClick, emptyMessage =
|
|
|
1870
1875
|
setAscending(true);
|
|
1871
1876
|
}
|
|
1872
1877
|
};
|
|
1873
|
-
return (jsxs("div", { className: [styles$
|
|
1878
|
+
return (jsxs("div", { className: [styles$k.table, className].filter(Boolean).join(' '), children: [jsx("div", { className: styles$k.header, children: headers.map((header) => (jsxs("button", { type: "button", disabled: !header.key, onClick: () => header.key && sort(header.key), children: [header.icon, jsx("span", { children: header.label }), header.key === sortKey && jsx("span", { "aria-label": ascending ? 'ascending' : 'descending', children: ascending ? '↑' : '↓' })] }, header.label))) }), !sortedRows.length ? jsx("div", { className: styles$k.empty, children: emptyMessage }) : jsx("div", { className: styles$k.body, children: sortedRows.map((row) => {
|
|
1874
1879
|
const values = [
|
|
1875
1880
|
teamCode ?? row.sportCode ?? '–',
|
|
1876
1881
|
formatTeamScheduleTravelDates(row.travelStartDate, row.travelEndDate),
|
|
1877
|
-
jsx(
|
|
1882
|
+
jsx(TripSummary, { row: row, onTripClick: onTripClick }),
|
|
1878
1883
|
row.airSegment,
|
|
1879
1884
|
row.groundSegment,
|
|
1880
1885
|
row.hotelSegment,
|
|
1881
1886
|
];
|
|
1882
|
-
return jsx("div", { className: styles$
|
|
1887
|
+
return jsx("div", { className: styles$k.row, children: values.map((value, index) => jsxs("div", { className: styles$k.cell, children: [jsxs("span", { className: styles$k.mobileLabel, children: [headers[index].icon, headers[index].label] }), jsx("div", { children: value || '–' })] }, headers[index].label)) }, row.masterTripGUID || row.tripName);
|
|
1883
1888
|
}) })] }));
|
|
1884
1889
|
};
|
|
1885
1890
|
|
|
1886
|
-
var styles$
|
|
1891
|
+
var styles$j = {"tripRow":"TeamScheduleEditor-module_tripRow__EgrxR","eventRow":"TeamScheduleEditor-module_eventRow__DaHf9","cell":"TeamScheduleEditor-module_cell__eocMi","actionsCell":"TeamScheduleEditor-module_actionsCell__mQ-30","services":"TeamScheduleEditor-module_services__DvbXH","inactiveService":"TeamScheduleEditor-module_inactiveService__WcyOT","gtrButton":"TeamScheduleEditor-module_gtrButton__D1ZXr","eventList":"TeamScheduleEditor-module_eventList__-F-3-"};
|
|
1887
1892
|
|
|
1888
1893
|
const EMPTY_EVENT = {
|
|
1889
1894
|
eventDate: '',
|
|
@@ -1907,37 +1912,37 @@ const TripRow = ({ trip, editing, selected, disabled, onSelectedChange, onEdit,
|
|
|
1907
1912
|
const [draft, setDraft] = useState(editing);
|
|
1908
1913
|
const values = draft ?? editing;
|
|
1909
1914
|
if (editing && values) {
|
|
1910
|
-
return (jsxs("form", { className: styles$
|
|
1915
|
+
return (jsxs("form", { className: styles$j.tripRow, "aria-label": `Edit trip ${trip.tripName}`, onSubmit: (event) => {
|
|
1911
1916
|
event.preventDefault();
|
|
1912
1917
|
onSave(values);
|
|
1913
|
-
}, children: [jsx("div", { className: styles$
|
|
1918
|
+
}, children: [jsx("div", { className: styles$j.cell, children: jsx(Checkbox, { "aria-label": `Select trip ${trip.tripName}`, checked: selected, disabled: true }) }), jsx("div", { className: styles$j.cell, children: jsx("button", { type: "button", className: styles$j.gtrButton, "aria-label": `Open group travel request for ${trip.tripName}`, disabled: true, children: trip.gtrExists ? jsx(DocumentIcon, { size: 18 }) : jsx(PlusIcon$2, { size: 18 }) }) }), jsx("div", { className: styles$j.cell, "data-label": "Trvl Start", children: jsx(Input, { "aria-label": "Travel Start", type: "date", size: "sm", value: values.travelStartDate, onChange: (event) => setDraft({ ...values, travelStartDate: event.target.value }), required: true, fullWidth: true }) }), jsx("div", { className: styles$j.cell, "data-label": "Trvl End", children: jsx(Input, { "aria-label": "Travel End", type: "date", size: "sm", min: values.travelStartDate, value: values.travelEndDate, onChange: (event) => setDraft({ ...values, travelEndDate: event.target.value }), required: true, fullWidth: true }) }), jsx("div", { className: styles$j.cell, "data-label": "Trip Name", children: jsx(Input, { "aria-label": "Trip Name", size: "sm", value: values.tripName, onChange: (event) => setDraft({ ...values, tripName: event.target.value }), required: true, fullWidth: true }) }), jsx("div", { className: styles$j.cell, "data-label": "Services", children: jsx(ServiceCodes, { services: trip.services }) }), jsxs("div", { className: `${styles$j.cell} ${styles$j.actionsCell}`, children: [jsx(Button, { type: "submit", variant: "ghost", size: "sm", square: true, "aria-label": `Save trip ${trip.tripName}`, children: jsx(CheckIcon$2, { size: 17 }) }), jsx(Button, { type: "button", variant: "ghost", size: "sm", square: true, "aria-label": `Cancel trip ${trip.tripName}`, onClick: onCancel, children: jsx(XIcon, { size: 17 }) })] })] }));
|
|
1914
1919
|
}
|
|
1915
|
-
return (jsxs("div", { className: styles$
|
|
1920
|
+
return (jsxs("div", { className: styles$j.tripRow, children: [jsx("div", { className: styles$j.cell, children: jsx(Checkbox, { "aria-label": `Select trip ${trip.tripName}`, checked: selected, onChange: (event) => onSelectedChange(event.target.checked), disabled: disabled }) }), jsx("div", { className: styles$j.cell, children: jsx("button", { type: "button", className: styles$j.gtrButton, "aria-label": `Open group travel request for ${trip.tripName}`, onClick: onOpenGroupTravelRequest, disabled: disabled, children: trip.gtrExists ? jsx(DocumentIcon, { size: 18 }) : jsx(PlusIcon$2, { size: 18 }) }) }), jsx("div", { className: styles$j.cell, "data-label": "Trvl Start", children: dateLabel(trip.travelStartDate) }), jsx("div", { className: styles$j.cell, "data-label": "Trvl End", children: dateLabel(trip.travelEndDate) }), jsx("div", { className: styles$j.cell, "data-label": "Trip Name", children: trip.tripName }), jsx("div", { className: styles$j.cell, "data-label": "Services", children: jsx(ServiceCodes, { services: trip.services }) }), jsxs("div", { className: `${styles$j.cell} ${styles$j.actionsCell}`, children: [jsx(Button, { type: "button", variant: "ghost", size: "sm", square: true, "aria-label": `Edit trip ${trip.tripName}`, onClick: onEdit, disabled: disabled, children: jsx(EditIcon$2, { size: 17 }) }), jsx(Button, { type: "button", variant: "ghost", size: "sm", square: true, "aria-label": `Delete trip ${trip.tripName}`, onClick: onDelete, disabled: disabled, children: jsx(TrashIcon$2, { size: 17 }) })] })] }));
|
|
1916
1921
|
};
|
|
1917
|
-
const ServiceCodes = ({ services }) => (jsx("div", { className: styles$
|
|
1922
|
+
const ServiceCodes = ({ services }) => (jsx("div", { className: styles$j.services, children: serviceLabels(services).map(({ service, active }) => jsx("span", { className: active ? '' : styles$j.inactiveService, children: service }, service)) }));
|
|
1918
1923
|
const EventRow = ({ event, editing, selected, disabled, opponentOptions, onSelectedChange, onEdit, onSave, onCancel, onDelete, }) => {
|
|
1919
1924
|
const [draft, setDraft] = useState(editing);
|
|
1920
1925
|
const values = draft ?? editing;
|
|
1921
1926
|
if (editing && values) {
|
|
1922
|
-
return (jsxs("form", { className: styles$
|
|
1927
|
+
return (jsxs("form", { className: styles$j.eventRow, "aria-label": `Edit event ${event.eventTitle}`, onSubmit: (submitEvent) => {
|
|
1923
1928
|
submitEvent.preventDefault();
|
|
1924
1929
|
onSave(values);
|
|
1925
|
-
}, children: [jsx("div", { className: styles$
|
|
1930
|
+
}, children: [jsx("div", { className: styles$j.cell, children: jsx(Checkbox, { "aria-label": `Select event ${event.eventTitle}`, checked: selected, disabled: true }) }), jsx("div", { className: styles$j.cell, "data-label": "Event Date", children: jsx(Input, { "aria-label": "Event Date", type: "date", size: "sm", value: values.eventDate, onChange: (changeEvent) => setDraft({ ...values, eventDate: changeEvent.target.value }), required: true, fullWidth: true }) }), jsxs("div", { className: styles$j.cell, "data-label": "Opponent/Host", children: [jsx(Input, { "aria-label": "Opponent or Host", size: "sm", list: "team-schedule-opponents", value: values.opponent, onChange: (changeEvent) => {
|
|
1926
1931
|
const opponent = changeEvent.target.value;
|
|
1927
1932
|
setDraft({ ...values, opponent, eventTitle: values.eventTitle || opponent });
|
|
1928
|
-
}, required: true, fullWidth: true }), jsx("datalist", { id: "team-schedule-opponents", children: opponentOptions.map((option) => jsx("option", { value: option }, option)) })] }), jsx("div", { className: styles$
|
|
1933
|
+
}, required: true, fullWidth: true }), jsx("datalist", { id: "team-schedule-opponents", children: opponentOptions.map((option) => jsx("option", { value: option }, option)) })] }), jsx("div", { className: styles$j.cell, "data-label": "Event Title", children: jsx(Input, { "aria-label": "Event Title", size: "sm", value: values.eventTitle, onChange: (changeEvent) => setDraft({ ...values, eventTitle: changeEvent.target.value }), required: true, fullWidth: true }) }), jsx("div", { className: styles$j.cell, "data-label": "Hm/Awy", children: jsx(Select, { "aria-label": "Home or Away", size: "sm", options: ['Home', 'Away', 'Neutral'].map((option) => ({ label: option, value: option })), value: values.homeOrAway, onChange: (changeEvent) => setDraft({ ...values, homeOrAway: changeEvent.target.value }), fullWidth: true }) }), jsxs("div", { className: `${styles$j.cell} ${styles$j.actionsCell}`, children: [jsx(Button, { type: "submit", variant: "ghost", size: "sm", square: true, "aria-label": `Save event ${event.eventTitle}`, children: jsx(CheckIcon$2, { size: 17 }) }), jsx(Button, { type: "button", variant: "ghost", size: "sm", square: true, "aria-label": `Cancel event ${event.eventTitle}`, onClick: onCancel, children: jsx(XIcon, { size: 17 }) })] })] }));
|
|
1929
1934
|
}
|
|
1930
|
-
return (jsxs("div", { className: styles$
|
|
1935
|
+
return (jsxs("div", { className: styles$j.eventRow, children: [jsx("div", { className: styles$j.cell, children: jsx(Checkbox, { "aria-label": `Select event ${event.eventTitle}`, checked: selected, onChange: (changeEvent) => onSelectedChange(changeEvent.target.checked), disabled: disabled || event.mergeable === false }) }), jsx("div", { className: styles$j.cell, "data-label": "Event Date", children: dateLabel(event.eventDate) }), jsx("div", { className: styles$j.cell, "data-label": "Opponent/Host", children: event.opponent || '–' }), jsx("div", { className: styles$j.cell, "data-label": "Event Title", children: event.eventTitle || '–' }), jsx("div", { className: styles$j.cell, "data-label": "Hm/Awy", children: event.homeOrAway }), jsxs("div", { className: `${styles$j.cell} ${styles$j.actionsCell}`, children: [jsx(Button, { type: "button", variant: "ghost", size: "sm", square: true, "aria-label": `Edit event ${event.eventTitle}`, onClick: onEdit, disabled: disabled, children: jsx(EditIcon$2, { size: 17 }) }), jsx(Button, { type: "button", variant: "ghost", size: "sm", square: true, "aria-label": `Delete event ${event.eventTitle}`, onClick: onDelete, disabled: disabled, children: jsx(TrashIcon$2, { size: 17 }) })] })] }));
|
|
1931
1936
|
};
|
|
1932
1937
|
const NewEventRow = ({ values: initialValues, opponentOptions, onSave, onCancel, }) => {
|
|
1933
1938
|
const [values, setValues] = useState(initialValues);
|
|
1934
|
-
return (jsxs("form", { className: styles$
|
|
1939
|
+
return (jsxs("form", { className: styles$j.eventRow, "aria-label": "Add event", onSubmit: (event) => {
|
|
1935
1940
|
event.preventDefault();
|
|
1936
1941
|
onSave(values);
|
|
1937
|
-
}, children: [jsx("div", { className: styles$
|
|
1942
|
+
}, children: [jsx("div", { className: styles$j.cell, children: jsx(Checkbox, { "aria-label": "Select new event", disabled: true }) }), jsx("div", { className: styles$j.cell, "data-label": "Event Date", children: jsx(Input, { "aria-label": "Event Date", type: "date", size: "sm", value: values.eventDate, onChange: (event) => setValues({ ...values, eventDate: event.target.value }), required: true, fullWidth: true }) }), jsxs("div", { className: styles$j.cell, "data-label": "Opponent/Host", children: [jsx(Input, { "aria-label": "Opponent or Host", size: "sm", list: "team-schedule-new-opponents", value: values.opponent, onChange: (event) => {
|
|
1938
1943
|
const opponent = event.target.value;
|
|
1939
1944
|
setValues({ ...values, opponent, eventTitle: values.eventTitle || opponent });
|
|
1940
|
-
}, required: true, fullWidth: true }), jsx("datalist", { id: "team-schedule-new-opponents", children: opponentOptions.map((option) => jsx("option", { value: option }, option)) })] }), jsx("div", { className: styles$
|
|
1945
|
+
}, required: true, fullWidth: true }), jsx("datalist", { id: "team-schedule-new-opponents", children: opponentOptions.map((option) => jsx("option", { value: option }, option)) })] }), jsx("div", { className: styles$j.cell, "data-label": "Event Title", children: jsx(Input, { "aria-label": "Event Title", size: "sm", value: values.eventTitle, onChange: (event) => setValues({ ...values, eventTitle: event.target.value }), required: true, fullWidth: true }) }), jsx("div", { className: styles$j.cell, "data-label": "Hm/Awy", children: jsx(Select, { "aria-label": "Home or Away", size: "sm", options: ['Home', 'Away', 'Neutral'].map((option) => ({ label: option, value: option })), value: values.homeOrAway, onChange: (event) => setValues({ ...values, homeOrAway: event.target.value }), fullWidth: true }) }), jsxs("div", { className: `${styles$j.cell} ${styles$j.actionsCell}`, children: [jsx(Button, { type: "submit", variant: "ghost", size: "sm", square: true, "aria-label": "Save new event", children: jsx(CheckIcon$2, { size: 17 }) }), jsx(Button, { type: "button", variant: "ghost", size: "sm", square: true, "aria-label": "Cancel new event", onClick: onCancel, children: jsx(XIcon, { size: 17 }) })] })] }));
|
|
1941
1946
|
};
|
|
1942
1947
|
const TeamScheduleEditor = ({ rows, initialRows = [], opponentOptions = [], onChange, onSaveTrip, onDeleteTrip, onSaveEvent, onDeleteEvent, onOpenGroupTravelRequest, onSelectedTripsChange, onSelectedEventsChange, className, }) => {
|
|
1943
1948
|
const [internalRows, setInternalRows] = useState(initialRows);
|
|
@@ -2009,7 +2014,7 @@ const TeamScheduleEditor = ({ rows, initialRows = [], opponentOptions = [], onCh
|
|
|
2009
2014
|
const tableRows = scheduleRows.map((trip) => ({
|
|
2010
2015
|
id: trip.id,
|
|
2011
2016
|
trip: (jsx(TripRow, { trip: trip, editing: editState?.kind === 'trip' && editState.tripId === trip.id ? editState.values : undefined, selected: selectedTrips.includes(trip.id), disabled: Boolean(editState), onSelectedChange: (selected) => changeSelectedTrips(toggleSelection(selectedTrips, trip.id, selected)), onEdit: () => setEditState({ kind: 'trip', tripId: trip.id, values: { travelStartDate: trip.travelStartDate, travelEndDate: trip.travelEndDate, tripName: trip.tripName } }), onSave: (values) => saveTrip(trip, values), onCancel: () => setEditState(null), onDelete: () => setDeleteState({ kind: 'trip', trip }), onOpenGroupTravelRequest: () => onOpenGroupTravelRequest?.(trip) }, editState?.kind === 'trip' && editState.tripId === trip.id ? `trip-edit-${trip.id}` : `trip-view-${trip.id}`)),
|
|
2012
|
-
events: (jsx("div", { className: styles$
|
|
2017
|
+
events: (jsx("div", { className: styles$j.eventList, children: trip.events.map((event) => (jsx(EventRow, { event: event, editing: editState?.kind === 'event' && editState.eventId === event.id ? editState.values : undefined, selected: selectedEvents.includes(event.id), disabled: Boolean(editState), opponentOptions: opponentOptions, onSelectedChange: (selected) => changeSelectedEvents(toggleSelection(selectedEvents, event.id, selected)), onEdit: () => setEditState({ kind: 'event', tripId: trip.id, eventId: event.id, values: { eventDate: event.eventDate, opponent: event.opponent, eventTitle: event.eventTitle, homeOrAway: event.homeOrAway } }), onSave: (values) => saveEvent(trip, event, values), onCancel: () => setEditState(null), onDelete: () => setDeleteState({ kind: 'event', trip, event }) }, editState?.kind === 'event' && editState.eventId === event.id ? `event-edit-${event.id}` : `event-view-${event.id}`))) })),
|
|
2013
2018
|
}));
|
|
2014
2019
|
if (editState?.kind === 'new-event') {
|
|
2015
2020
|
tableRows.push({
|
|
@@ -2036,7 +2041,7 @@ const TeamScheduleEditor = ({ rows, initialRows = [], opponentOptions = [], onCh
|
|
|
2036
2041
|
], rows: tableRows, onAddEvent: () => setEditState({ kind: 'new-event', values: EMPTY_EVENT }), addEventDisabled: Boolean(editState) }), jsx(ConfirmModal, { isOpen: Boolean(deleteState), onClose: () => setDeleteState(null), onConfirm: confirmDelete, title: `Delete ${deleteState?.kind === 'trip' ? 'Trip' : 'Event'}`, message: `Are you sure you would like to delete this ${deleteState?.kind ?? 'record'}?`, confirmText: "Delete", destructive: true })] }));
|
|
2037
2042
|
};
|
|
2038
2043
|
|
|
2039
|
-
var styles$
|
|
2044
|
+
var styles$i = {"toolbar":"TeamTravelCalendarViews-module_toolbar__5t4I2","todayButton":"TeamTravelCalendarViews-module_todayButton__-C90j","periodNavigation":"TeamTravelCalendarViews-module_periodNavigation__J9S80","navigationButton":"TeamTravelCalendarViews-module_navigationButton__j-2Bn","periodButton":"TeamTravelCalendarViews-module_periodButton__W-UmM","calendarView":"TeamTravelCalendarViews-module_calendarView__FVQKl","cardView":"TeamTravelCalendarViews-module_cardView__3w9PZ","listView":"TeamTravelCalendarViews-module_listView__4Ro3J","weekdayRow":"TeamTravelCalendarViews-module_weekdayRow__rPqds","calendarGrid":"TeamTravelCalendarViews-module_calendarGrid__L3MoK","weekday":"TeamTravelCalendarViews-module_weekday__Ozwh8","weekdayShort":"TeamTravelCalendarViews-module_weekdayShort__kAxAP","calendarDay":"TeamTravelCalendarViews-module_calendarDay__imFhq","outsidePeriod":"TeamTravelCalendarViews-module_outsidePeriod__FkfcK","today":"TeamTravelCalendarViews-module_today__h-el6","dayNumber":"TeamTravelCalendarViews-module_dayNumber__d4FpZ","dayItems":"TeamTravelCalendarViews-module_dayItems__r5TFy","tripEvent":"TeamTravelCalendarViews-module_tripEvent__Np4nN","sportTag":"TeamTravelCalendarViews-module_sportTag__-EPtk","dueSportTag":"TeamTravelCalendarViews-module_dueSportTag__tb-mi","eventName":"TeamTravelCalendarViews-module_eventName__bZBBx","dueDateName":"TeamTravelCalendarViews-module_dueDateName__LX6Xv","dueDateEvent":"TeamTravelCalendarViews-module_dueDateEvent__HV2JF","statusButton":"TeamTravelCalendarViews-module_statusButton__SNqiu","listStatusButton":"TeamTravelCalendarViews-module_listStatusButton__vT9zM","completeStatus":"TeamTravelCalendarViews-module_completeStatus__3Vd2E","overdueStatus":"TeamTravelCalendarViews-module_overdueStatus__6G4eC","teamGroups":"TeamTravelCalendarViews-module_teamGroups__9g2sK","teamGroup":"TeamTravelCalendarViews-module_teamGroup__Rlmp2","teamPanel":"TeamTravelCalendarViews-module_teamPanel__u1E8J","teamIdentity":"TeamTravelCalendarViews-module_teamIdentity__Pe53X","teamCode":"TeamTravelCalendarViews-module_teamCode__w9Utr","infoTiles":"TeamTravelCalendarViews-module_infoTiles__PyPHh","infoTile":"TeamTravelCalendarViews-module_infoTile__t-mEg","cardsScroller":"TeamTravelCalendarViews-module_cardsScroller__Y6aJw","tripCard":"TeamTravelCalendarViews-module_tripCard__2LPBR","featuredCard":"TeamTravelCalendarViews-module_featuredCard__B4nvH","tripCardHeader":"TeamTravelCalendarViews-module_tripCardHeader__-ARSM","dueDateColumnHeader":"TeamTravelCalendarViews-module_dueDateColumnHeader__nayVI","dateLabel":"TeamTravelCalendarViews-module_dateLabel__OJY64","progressBadge":"TeamTravelCalendarViews-module_progressBadge__vJoU9","progressCircle":"TeamTravelCalendarViews-module_progressCircle__8YfEC","tripCardTitle":"TeamTravelCalendarViews-module_tripCardTitle__E-YJ5","serviceGrid":"TeamTravelCalendarViews-module_serviceGrid__5rwTv","serviceTile":"TeamTravelCalendarViews-module_serviceTile__F1Oge","air":"TeamTravelCalendarViews-module_air__Ald0h","ground":"TeamTravelCalendarViews-module_ground__eN71m","hotel":"TeamTravelCalendarViews-module_hotel__paHF-","serviceLabel":"TeamTravelCalendarViews-module_serviceLabel__vaNlz","bookingStatus":"TeamTravelCalendarViews-module_bookingStatus__xrru7","requestStatus":"TeamTravelCalendarViews-module_requestStatus__Oeppm","tableStatus":"TeamTravelCalendarViews-module_tableStatus__yoM6Z","tableRequest":"TeamTravelCalendarViews-module_tableRequest__LRSjx","tripEvents":"TeamTravelCalendarViews-module_tripEvents__36pK5","tripEventDetail":"TeamTravelCalendarViews-module_tripEventDetail__ev8-C","star":"TeamTravelCalendarViews-module_star__w0-ji","opponentLine":"TeamTravelCalendarViews-module_opponentLine__35K7l","homeAway":"TeamTravelCalendarViews-module_homeAway__8dpYe","venueLine":"TeamTravelCalendarViews-module_venueLine__il1nq","dueDateColumn":"TeamTravelCalendarViews-module_dueDateColumn__dHHT9","dueDateCards":"TeamTravelCalendarViews-module_dueDateCards__oQYwk","dueDateCard":"TeamTravelCalendarViews-module_dueDateCard__E61iS","dueCardCopy":"TeamTravelCalendarViews-module_dueCardCopy__dxvuE","emptyState":"TeamTravelCalendarViews-module_emptyState__6Rwjp","resultCount":"TeamTravelCalendarViews-module_resultCount__rtH-2","tableScroller":"TeamTravelCalendarViews-module_tableScroller__PCl6F","travelTable":"TeamTravelCalendarViews-module_travelTable__gxhK9","tableSport":"TeamTravelCalendarViews-module_tableSport__CDOnL","tableLink":"TeamTravelCalendarViews-module_tableLink__PKEym","tableProgress":"TeamTravelCalendarViews-module_tableProgress__wsMuj","dueDateTable":"TeamTravelCalendarViews-module_dueDateTable__YwP10","weekdayLong":"TeamTravelCalendarViews-module_weekdayLong__irl1L"};
|
|
2040
2045
|
|
|
2041
2046
|
const ChevronLeft$1 = () => (jsx("svg", { viewBox: "0 0 24 24", width: "18", height: "18", fill: "none", stroke: "currentColor", strokeWidth: "2", "aria-hidden": "true", children: jsx("path", { d: "m15 18-6-6 6-6" }) }));
|
|
2042
2047
|
const ChevronRight$2 = () => (jsx("svg", { viewBox: "0 0 24 24", width: "18", height: "18", fill: "none", stroke: "currentColor", strokeWidth: "2", "aria-hidden": "true", children: jsx("path", { d: "m9 18 6-6-6-6" }) }));
|
|
@@ -2097,7 +2102,7 @@ const sportColor = (sportCode) => {
|
|
|
2097
2102
|
return '#D1C1C3';
|
|
2098
2103
|
return '#8AC6D9';
|
|
2099
2104
|
};
|
|
2100
|
-
const TeamTravelCalendarToolbar = ({ duration, label = '', navigation, onDurationChange, onToday, onPrevious, onNext, className = '', }) => (jsxs("div", { className: [styles$
|
|
2105
|
+
const TeamTravelCalendarToolbar = ({ duration, label = '', navigation, onDurationChange, onToday, onPrevious, onNext, className = '', }) => (jsxs("div", { className: [styles$i.toolbar, className].filter(Boolean).join(' '), "data-test": "calendar-toolbar", children: [jsx("button", { type: "button", className: styles$i.todayButton, onClick: onToday, "data-test": "calendar-today", children: "Today" }), jsx(SegmentedSelector, { value: duration, size: "sm", ariaLabel: "Calendar duration", onChange: (value) => onDurationChange?.(value), options: [{ id: 'month', label: 'Month' }, { id: 'week', label: 'Week' }] }), navigation ?? (jsxs("div", { className: styles$i.periodNavigation, children: [jsx("button", { type: "button", className: styles$i.navigationButton, "aria-label": `Previous ${duration}`, onClick: onPrevious, children: jsx(ChevronLeft$1, {}) }), jsx("button", { type: "button", className: styles$i.periodButton, children: label }), jsx("button", { type: "button", className: styles$i.navigationButton, "aria-label": `Next ${duration}`, onClick: onNext, children: jsx(ChevronRight$2, {}) })] }))] }));
|
|
2101
2106
|
const getVisibleDates = (activeDate, duration) => {
|
|
2102
2107
|
const active = parseDate(activeDate);
|
|
2103
2108
|
if (duration === 'week') {
|
|
@@ -2118,52 +2123,52 @@ const TeamTravelCalendarView = ({ activeDate, duration = 'month', type = 'trips'
|
|
|
2118
2123
|
const todayKey = dateKey(today ? parseDate(today) : new Date());
|
|
2119
2124
|
const shortWeekdays = ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'];
|
|
2120
2125
|
const longWeekdays = ['Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday', 'Sunday'];
|
|
2121
|
-
return (jsxs("section", { className: [styles$
|
|
2126
|
+
return (jsxs("section", { className: [styles$i.calendarView, className].filter(Boolean).join(' '), "aria-label": "Team travel calendar", children: [toolbar, jsx("div", { className: styles$i.weekdayRow, role: "row", children: longWeekdays.map((weekday, index) => (jsxs("div", { className: styles$i.weekday, role: "columnheader", children: [jsx("span", { className: styles$i.weekdayLong, children: weekday }), jsx("span", { className: styles$i.weekdayShort, children: shortWeekdays[index] })] }, weekday))) }), jsx("div", { className: styles$i.calendarGrid, role: "grid", children: visibleDates.map((date) => {
|
|
2122
2127
|
const key = dateKey(date);
|
|
2123
2128
|
const currentPeriod = duration === 'week' || date.getMonth() === active.getMonth();
|
|
2124
2129
|
const dayTrips = trips.filter((trip) => key >= dateKey(parseDate(trip.tripStart)) && key <= dateKey(parseDate(trip.tripEnd)));
|
|
2125
2130
|
const dayDueDates = dueDates.filter((dueDate) => dateKey(parseDate(dueDate.duedate)) === key);
|
|
2126
2131
|
return (jsxs("div", { role: "gridcell", "aria-label": date.toLocaleDateString('en-US', { weekday: 'long', month: 'long', day: 'numeric', year: 'numeric' }), className: [
|
|
2127
|
-
styles$
|
|
2128
|
-
!currentPeriod ? styles$
|
|
2129
|
-
key === todayKey ? styles$
|
|
2130
|
-
].filter(Boolean).join(' '), children: [jsx("time", { className: styles$
|
|
2132
|
+
styles$i.calendarDay,
|
|
2133
|
+
!currentPeriod ? styles$i.outsidePeriod : '',
|
|
2134
|
+
key === todayKey ? styles$i.today : '',
|
|
2135
|
+
].filter(Boolean).join(' '), children: [jsx("time", { className: styles$i.dayNumber, dateTime: key, children: date.getDate() }), jsxs("div", { className: styles$i.dayItems, children: [type === 'trips' && dayTrips.map((trip) => {
|
|
2131
2136
|
const color = sportColor(trip.sportCode);
|
|
2132
|
-
return (jsxs("button", { type: "button", className: styles$
|
|
2137
|
+
return (jsxs("button", { type: "button", className: styles$i.tripEvent, style: { '--event-color': color }, onClick: () => onTripClick?.(trip), "aria-label": `${trip.sportCode}: ${trip.tripName}`, title: `${trip.sportCode}: ${trip.tripName}`, children: [jsx("span", { className: styles$i.sportTag, children: trip.sportCode }), jsx("span", { className: styles$i.eventName, children: trip.tripName })] }, trip.masterTripGUID));
|
|
2133
2138
|
}), type === 'due_dates' && dayDueDates.map((dueDate) => {
|
|
2134
2139
|
const completed = isCompleted(dueDate);
|
|
2135
2140
|
const overdue = !completed && parseDate(dueDate.duedate) < parseDate(today ?? dateKey(new Date()));
|
|
2136
|
-
return (jsxs("div", { className: styles$
|
|
2141
|
+
return (jsxs("div", { className: styles$i.dueDateEvent, role: "button", tabIndex: 0, onClick: () => onDueDateClick?.(key, dueDate), onKeyDown: (event) => {
|
|
2137
2142
|
if (event.key === 'Enter' || event.key === ' ')
|
|
2138
2143
|
onDueDateClick?.(key, dueDate);
|
|
2139
|
-
}, children: [jsx("button", { type: "button", className: [styles$
|
|
2144
|
+
}, children: [jsx("button", { type: "button", className: [styles$i.statusButton, completed ? styles$i.completeStatus : '', overdue ? styles$i.overdueStatus : ''].filter(Boolean).join(' '), "aria-label": `${completed ? 'Mark incomplete' : 'Mark complete'}: ${dueDate.tasktitle}`, onClick: (event) => {
|
|
2140
2145
|
event.stopPropagation();
|
|
2141
2146
|
onDueDateToggle?.(dueDate);
|
|
2142
|
-
}, children: completed ? jsx(CheckGlyph, {}) : jsx(CircleGlyph, {}) }), jsx("span", { className: styles$
|
|
2147
|
+
}, children: completed ? jsx(CheckGlyph, {}) : jsx(CircleGlyph, {}) }), jsx("span", { className: styles$i.dueSportTag, style: { backgroundColor: sportColor(dueDate.sportCode) }, children: dueDate.sportCode }), jsx("span", { className: styles$i.dueDateName, children: dueDate.tasktitle })] }, dueDate.taskid));
|
|
2143
2148
|
})] })] }, key));
|
|
2144
2149
|
}) })] }));
|
|
2145
2150
|
};
|
|
2146
|
-
const ServiceTile = ({ label, status, icon, tone }) => (jsxs("div", { className: [styles$
|
|
2151
|
+
const ServiceTile = ({ label, status, icon, tone }) => (jsxs("div", { className: [styles$i.serviceTile, styles$i[tone]].join(' '), children: [jsxs("div", { className: styles$i.serviceLabel, children: [icon, jsx("span", { children: label })] }), status ? jsx("span", { className: styles$i.bookingStatus, children: status }) : jsx("span", { className: styles$i.requestStatus, children: "Request" })] }));
|
|
2147
2152
|
const ProgressBadge = ({ completed, total }) => {
|
|
2148
2153
|
const progress = total > 0 ? Math.round((completed / total) * 100) : 0;
|
|
2149
|
-
return (jsxs("span", { className: styles$
|
|
2154
|
+
return (jsxs("span", { className: styles$i.progressBadge, children: [jsxs("span", { children: [completed, "/", total] }), jsx("span", { className: styles$i.progressCircle, style: { '--progress': `${progress * 3.6}deg` }, "aria-label": `${progress}% complete` })] }));
|
|
2150
2155
|
};
|
|
2151
2156
|
const TripCard = ({ trip, featured, onClick }) => {
|
|
2152
2157
|
const dueDates = trip.duedates ?? [];
|
|
2153
2158
|
const completeCount = dueDates.filter(isCompleted).length;
|
|
2154
|
-
return (jsxs("button", { type: "button", className: [styles$
|
|
2159
|
+
return (jsxs("button", { type: "button", className: [styles$i.tripCard, featured ? styles$i.featuredCard : ''].filter(Boolean).join(' '), onClick: onClick, children: [jsxs("div", { className: styles$i.tripCardHeader, children: [jsxs("span", { className: styles$i.dateLabel, children: [jsx(CalendarGlyph, {}), formatDateRange(trip.tripStart, trip.tripEnd)] }), jsx(ProgressBadge, { completed: completeCount, total: dueDates.length })] }), jsx("h3", { className: styles$i.tripCardTitle, children: trip.tripName }), jsxs("div", { className: styles$i.serviceGrid, children: [jsx(ServiceTile, { label: "Air", status: trip.air_status || trip.charter_status, icon: jsx(PlaneGlyph, {}), tone: "air" }), jsx(ServiceTile, { label: "Ground", status: trip.ground_status, icon: jsx(BusGlyph, {}), tone: "ground" }), jsx(ServiceTile, { label: "Hotel", status: trip.hotel_status, icon: jsx(HotelGlyph, {}), tone: "hotel" })] }), jsx("div", { className: styles$i.tripEvents, children: (trip.events ?? []).map((event, index) => (jsxs("div", { className: styles$i.tripEventDetail, children: [jsx("span", { className: styles$i.star, children: jsx(StarGlyph, {}) }), jsxs("div", { children: [jsxs("div", { className: styles$i.opponentLine, children: [jsx("strong", { children: event.eventtitle || event.opponentname }), jsx("span", { className: styles$i.homeAway, children: event.homeoraway || 'Away' })] }), jsxs("span", { className: styles$i.venueLine, children: [event.venuename ? `${event.venuename} • ` : '', formatShortDate(event.eventstartdate)] })] })] }, event.id ?? `${event.eventtitle}-${index}`))) })] }));
|
|
2155
2160
|
};
|
|
2156
2161
|
const DueDateCard = ({ dueDate, onClick, onToggle }) => {
|
|
2157
2162
|
const completed = isCompleted(dueDate);
|
|
2158
|
-
return (jsxs("div", { className: styles$
|
|
2163
|
+
return (jsxs("div", { className: styles$i.dueDateCard, role: "button", tabIndex: 0, onClick: onClick, onKeyDown: (event) => {
|
|
2159
2164
|
if (event.key === 'Enter' || event.key === ' ')
|
|
2160
2165
|
onClick?.();
|
|
2161
|
-
}, children: [jsx("button", { type: "button", className: [styles$
|
|
2166
|
+
}, children: [jsx("button", { type: "button", className: [styles$i.statusButton, completed ? styles$i.completeStatus : ''].filter(Boolean).join(' '), "aria-label": `${completed ? 'Mark incomplete' : 'Mark complete'}: ${dueDate.tasktitle}`, onClick: (event) => {
|
|
2162
2167
|
event.stopPropagation();
|
|
2163
2168
|
onToggle?.();
|
|
2164
|
-
}, children: completed ? jsx(CheckGlyph, {}) : jsx(CircleGlyph, {}) }), jsxs("div", { className: styles$
|
|
2169
|
+
}, children: completed ? jsx(CheckGlyph, {}) : jsx(CircleGlyph, {}) }), jsxs("div", { className: styles$i.dueCardCopy, children: [jsx("strong", { children: dueDate.tasktitle }), dueDate.description && jsx("span", { children: dueDate.description }), jsxs("small", { children: [dueDate.tripName, dueDate.tripStart ? ` • ${formatShortDate(dueDate.tripStart)}` : ''] })] })] }));
|
|
2165
2170
|
};
|
|
2166
|
-
const TeamTravelCalendarCardView = ({ groups, type = 'trips', toolbar, onTripClick, onDueDateClick, onDueDateToggle, className = '', }) => (jsxs("section", { className: [styles$
|
|
2171
|
+
const TeamTravelCalendarCardView = ({ groups, type = 'trips', toolbar, onTripClick, onDueDateClick, onDueDateToggle, className = '', }) => (jsxs("section", { className: [styles$i.cardView, className].filter(Boolean).join(' '), "aria-label": "Team travel cards", children: [toolbar, jsx("div", { className: styles$i.teamGroups, children: groups.map((group) => {
|
|
2167
2172
|
const groupDueDates = group.trips.flatMap((trip) => (trip.duedates ?? []).map((dueDate) => ({
|
|
2168
2173
|
...dueDate,
|
|
2169
2174
|
sportCode: dueDate.sportCode ?? group.sportCode,
|
|
@@ -2176,11 +2181,11 @@ const TeamTravelCalendarCardView = ({ groups, type = 'trips', toolbar, onTripCli
|
|
|
2176
2181
|
result[key] = [...(result[key] ?? []), dueDate];
|
|
2177
2182
|
return result;
|
|
2178
2183
|
}, {})).sort(([left], [right]) => left.localeCompare(right));
|
|
2179
|
-
return (jsxs("article", { className: styles$
|
|
2184
|
+
return (jsxs("article", { className: styles$i.teamGroup, children: [jsxs("div", { className: styles$i.teamPanel, children: [jsxs("div", { className: styles$i.teamIdentity, children: [jsx("span", { className: styles$i.teamCode, children: group.sportCode }), jsx("strong", { children: group.sportDescription })] }), jsxs("div", { className: styles$i.infoTiles, children: [jsxs("div", { className: styles$i.infoTile, children: [jsx(PlaneGlyph, {}), jsx("strong", { children: group.upcomingCount ?? group.trips.length }), jsx("span", { children: "Upcoming" })] }), jsxs("div", { className: styles$i.infoTile, children: [jsx(CalendarGlyph, {}), jsx("strong", { children: formatShortDate(group.nextTripStartDate ?? group.trips[0]?.tripStart) }), jsx("span", { children: "Next Trip" })] })] })] }), jsxs("div", { className: styles$i.cardsScroller, children: [type === 'trips' && group.trips.map((trip, index) => (jsx(TripCard, { trip: trip, featured: index === 0, onClick: () => onTripClick?.(trip) }, trip.masterTripGUID))), type === 'due_dates' && dueDateGroups.map(([dueDate, items], index) => (jsxs("div", { className: [styles$i.dueDateColumn, index === 0 ? styles$i.featuredCard : ''].filter(Boolean).join(' '), children: [jsxs("div", { className: styles$i.dueDateColumnHeader, children: [jsxs("span", { className: styles$i.dateLabel, children: [jsx(CalendarGlyph, {}), formatLongDate(dueDate)] }), jsx(ProgressBadge, { completed: items.filter(isCompleted).length, total: items.length })] }), jsx("div", { className: styles$i.dueDateCards, children: items.map((item) => jsx(DueDateCard, { dueDate: item, onClick: () => onDueDateClick?.(item), onToggle: () => onDueDateToggle?.(item) }, item.taskid)) })] }, dueDate))), ((type === 'trips' && group.trips.length === 0) || (type === 'due_dates' && dueDateGroups.length === 0)) && (jsxs("div", { className: styles$i.emptyState, children: ["No ", type === 'trips' ? 'trips' : 'due dates', " found for ", group.sportDescription] }))] })] }, group.sportCode));
|
|
2180
2185
|
}) })] }));
|
|
2181
2186
|
const StatusPill$1 = ({ status }) => status
|
|
2182
|
-
? jsx("span", { className: styles$
|
|
2183
|
-
: jsx("span", { className: styles$
|
|
2187
|
+
? jsx("span", { className: styles$i.tableStatus, children: status })
|
|
2188
|
+
: jsx("span", { className: styles$i.tableRequest, children: "Request" });
|
|
2184
2189
|
const TeamTravelCalendarListView = ({ trips, type = 'trips', toolbar, periodLabel = '', upcomingTrips = trips.length, onTripClick, onDueDatesClick, onDueDateClick, onDueDateToggle, className = '', }) => {
|
|
2185
2190
|
const dueDates = trips.flatMap((trip) => (trip.duedates ?? []).map((dueDate) => ({
|
|
2186
2191
|
...dueDate,
|
|
@@ -2190,12 +2195,12 @@ const TeamTravelCalendarListView = ({ trips, type = 'trips', toolbar, periodLabe
|
|
|
2190
2195
|
tripStart: dueDate.tripStart ?? trip.tripStart,
|
|
2191
2196
|
masterTripGUID: dueDate.masterTripGUID ?? trip.masterTripGUID,
|
|
2192
2197
|
})));
|
|
2193
|
-
return (jsxs("section", { className: [styles$
|
|
2198
|
+
return (jsxs("section", { className: [styles$i.listView, className].filter(Boolean).join(' '), "aria-label": "Team travel list", children: [toolbar, type === 'trips' ? (jsxs(Fragment, { children: [jsxs("p", { className: styles$i.resultCount, children: ["Showing ", trips.length, " travel items (", upcomingTrips, " upcoming trips)"] }), jsx("div", { className: styles$i.tableScroller, children: jsxs("table", { className: styles$i.travelTable, children: [jsx("thead", { children: jsxs("tr", { children: [jsx("th", { children: "Sport" }), jsx("th", { children: "Travel Date(s)" }), jsx("th", { children: "Trip Name" }), jsx("th", { children: "Due Dates" }), jsx("th", { children: "Air" }), jsx("th", { children: "Ground" }), jsx("th", { children: "Hotel" })] }) }), jsx("tbody", { children: trips.map((trip) => {
|
|
2194
2199
|
const dueDatesForTrip = trip.duedates ?? [];
|
|
2195
|
-
return (jsxs("tr", { children: [jsx("td", { children: jsx("span", { className: styles$
|
|
2196
|
-
}) })] }) })] })) : (jsxs(Fragment, { children: [jsxs("p", { className: styles$
|
|
2200
|
+
return (jsxs("tr", { children: [jsx("td", { children: jsx("span", { className: styles$i.tableSport, children: trip.sportCode }) }), jsx("td", { children: formatDateRange(trip.tripStart, trip.tripEnd) }), jsx("td", { children: jsx("button", { type: "button", className: styles$i.tableLink, onClick: () => onTripClick?.(trip), children: trip.tripName }) }), jsx("td", { children: jsx("button", { type: "button", className: styles$i.tableProgress, onClick: () => onDueDatesClick?.(trip), children: jsx(ProgressBadge, { completed: dueDatesForTrip.filter(isCompleted).length, total: dueDatesForTrip.length }) }) }), jsx("td", { children: jsx(StatusPill$1, { status: trip.air_status || trip.charter_status }) }), jsx("td", { children: jsx(StatusPill$1, { status: trip.ground_status }) }), jsx("td", { children: jsx(StatusPill$1, { status: trip.hotel_status }) })] }, trip.masterTripGUID));
|
|
2201
|
+
}) })] }) })] })) : (jsxs(Fragment, { children: [jsxs("p", { className: styles$i.resultCount, children: ["Showing ", dueDates.length, " due date ", dueDates.length === 1 ? 'item' : 'items', periodLabel ? ` for ${periodLabel}` : ''] }), jsx("div", { className: styles$i.tableScroller, children: jsxs("table", { className: [styles$i.travelTable, styles$i.dueDateTable].join(' '), children: [jsx("thead", { children: jsxs("tr", { children: [jsx("th", { children: "Reminder" }), jsx("th", { children: "Description" }), jsx("th", { children: "Due Date" }), jsx("th", { children: "Trip Name" }), jsx("th", { children: "Trip Start Date" }), jsx("th", { children: "Service Type" }), jsx("th", { children: "Status" })] }) }), jsx("tbody", { children: dueDates.map((dueDate) => {
|
|
2197
2202
|
const completed = isCompleted(dueDate);
|
|
2198
|
-
return (jsxs("tr", { children: [jsx("td", { children: jsx("button", { type: "button", className: styles$
|
|
2203
|
+
return (jsxs("tr", { children: [jsx("td", { children: jsx("button", { type: "button", className: styles$i.tableLink, onClick: () => onDueDateClick?.(dueDate), children: dueDate.tasktitle }) }), jsx("td", { children: dueDate.description || '–' }), jsx("td", { children: formatLongDate(dueDate.duedate) }), jsx("td", { children: dueDate.tripName }), jsx("td", { children: formatLongDate(dueDate.tripStart) }), jsx("td", { children: dueDate.servicetype || '–' }), jsx("td", { children: jsx("button", { type: "button", className: [styles$i.listStatusButton, completed ? styles$i.completeStatus : ''].filter(Boolean).join(' '), "aria-label": `${completed ? 'Mark incomplete' : 'Mark complete'}: ${dueDate.tasktitle}`, onClick: () => onDueDateToggle?.(dueDate), children: completed ? jsx(CheckGlyph, {}) : jsx(CircleGlyph, {}) }) })] }, `${dueDate.masterTripGUID}-${dueDate.taskid}`));
|
|
2199
2204
|
}) })] }) })] }))] }));
|
|
2200
2205
|
};
|
|
2201
2206
|
const getTeamTravelCalendarPeriodLabel = (activeDate, duration) => {
|
|
@@ -2218,7 +2223,7 @@ const moveTeamTravelCalendarPeriod = (activeDate, duration, amount) => {
|
|
|
2218
2223
|
return dateKey(next);
|
|
2219
2224
|
};
|
|
2220
2225
|
|
|
2221
|
-
var styles$
|
|
2226
|
+
var styles$h = {"form":"TeamManagementForms-module_form__bF0qU","stack":"TeamManagementForms-module_stack__5XyWb","twoColumnGrid":"TeamManagementForms-module_twoColumnGrid__zKQM6","threeColumnGrid":"TeamManagementForms-module_threeColumnGrid__HiCa7","actions":"TeamManagementForms-module_actions__Y2lA0","sectionCard":"TeamManagementForms-module_sectionCard__IPv1F","blueSection":"TeamManagementForms-module_blueSection__FsxUA","sectionHeader":"TeamManagementForms-module_sectionHeader__rM4Oj","sectionIcon":"TeamManagementForms-module_sectionIcon__VkbW8","sectionHeading":"TeamManagementForms-module_sectionHeading__m8szw","badge":"TeamManagementForms-module_badge__IOqxe","optionalBadge":"TeamManagementForms-module_optionalBadge__PHhTy","completeBadge":"TeamManagementForms-module_completeBadge__ZLyyr","incompleteBadge":"TeamManagementForms-module_incompleteBadge__70kvV","middleNameField":"TeamManagementForms-module_middleNameField__43-7h","fieldHeader":"TeamManagementForms-module_fieldHeader__jG-Ej","fileField":"TeamManagementForms-module_fileField__JnFhb","instructions":"TeamManagementForms-module_instructions__qTJI6","sampleLink":"TeamManagementForms-module_sampleLink__L4qXl"};
|
|
2222
2227
|
|
|
2223
2228
|
const useManagedValues = (controlledValues, initialValues, onChange) => {
|
|
2224
2229
|
const [internalValues, setInternalValues] = useState(initialValues);
|
|
@@ -2233,10 +2238,10 @@ const useManagedValues = (controlledValues, initialValues, onChange) => {
|
|
|
2233
2238
|
};
|
|
2234
2239
|
const numericValue$1 = (value) => value === '' ? '' : Number(value);
|
|
2235
2240
|
const FormShell = ({ ariaLabel, children, className = '', disabled = false, onCancel, onSubmit, showActions = true, values, }) => {
|
|
2236
|
-
const content = (jsxs(Fragment, { children: [children, showActions && (jsxs("div", { className: styles$
|
|
2241
|
+
const content = (jsxs(Fragment, { children: [children, showActions && (jsxs("div", { className: styles$h.actions, children: [jsx(Button, { type: "button", variant: "secondary", onClick: onCancel, disabled: disabled, children: "Cancel" }), jsx(Button, { type: "submit", disabled: disabled, children: "Save" })] }))] }));
|
|
2237
2242
|
if (!showActions)
|
|
2238
|
-
return jsx("div", { className: `${styles$
|
|
2239
|
-
return (jsx("form", { "aria-label": ariaLabel, className: `${styles$
|
|
2243
|
+
return jsx("div", { className: `${styles$h.form} ${className}`, children: content });
|
|
2244
|
+
return (jsx("form", { "aria-label": ariaLabel, className: `${styles$h.form} ${className}`, onSubmit: (event) => {
|
|
2240
2245
|
event.preventDefault();
|
|
2241
2246
|
onSubmit?.(values);
|
|
2242
2247
|
}, children: content }));
|
|
@@ -2251,7 +2256,7 @@ const EMPTY_EQUIPMENT = {
|
|
|
2251
2256
|
};
|
|
2252
2257
|
const TeamEquipmentForm = ({ mode = 'Add', values, initialValues, onChange, onSubmit, onCancel, showActions = true, disabled = false, className, }) => {
|
|
2253
2258
|
const [formValues, updateValues] = useManagedValues(values, { ...EMPTY_EQUIPMENT, ...initialValues }, onChange);
|
|
2254
|
-
return (jsx(FormShell, { ariaLabel: `${mode} equipment`, className: className, disabled: disabled, onCancel: onCancel, onSubmit: onSubmit, showActions: showActions, values: formValues, children: jsxs("div", { className: styles$
|
|
2259
|
+
return (jsx(FormShell, { ariaLabel: `${mode} equipment`, className: className, disabled: disabled, onCancel: onCancel, onSubmit: onSubmit, showActions: showActions, values: formValues, children: jsxs("div", { className: styles$h.stack, children: [jsx(Input, { label: "Item Name *", value: formValues.description, onChange: (event) => updateValues({ description: event.target.value }), required: true, disabled: disabled, fullWidth: true }), jsxs("div", { className: styles$h.twoColumnGrid, children: [jsx(Input, { label: "Weight (lbs) *", type: "number", min: "0", step: "0.1", value: formValues.weight, onChange: (event) => updateValues({ weight: numericValue$1(event.target.value) }), required: true, disabled: disabled, fullWidth: true }), jsx(Input, { label: "Quantity *", type: "number", min: "1", step: "1", value: formValues.quantity, onChange: (event) => updateValues({ quantity: numericValue$1(event.target.value) }), required: true, disabled: disabled, fullWidth: true }), jsx(Input, { label: "Height (inches)", type: "number", min: "0", step: "0.1", value: formValues.height, onChange: (event) => updateValues({ height: numericValue$1(event.target.value) }), disabled: disabled, fullWidth: true }), jsx(Input, { label: "Width (inches)", type: "number", min: "0", step: "0.1", value: formValues.width, onChange: (event) => updateValues({ width: numericValue$1(event.target.value) }), disabled: disabled, fullWidth: true }), jsx(Input, { label: "Depth (inches)", type: "number", min: "0", step: "0.1", value: formValues.depth, onChange: (event) => updateValues({ depth: numericValue$1(event.target.value) }), disabled: disabled, fullWidth: true })] })] }) }));
|
|
2255
2260
|
};
|
|
2256
2261
|
const TeamUserAccessForm = ({ options, values, initialValues, onChange, onSubmit, onCancel, showActions = true, disabled = false, className, }) => {
|
|
2257
2262
|
const [formValues, updateValues] = useManagedValues(values, { userId: '', ...initialValues }, onChange);
|
|
@@ -2277,7 +2282,7 @@ const DEFAULT_SUPPLIERS = {
|
|
|
2277
2282
|
const TeamProgramForm = ({ values, initialValues, onChange, onSubmit, onCancel, showActions = true, disabled = false, className, supplierOptions, }) => {
|
|
2278
2283
|
const [formValues, updateValues] = useManagedValues(values, { type: 'Air', supplier: '', accountNumber: '', ...initialValues }, onChange);
|
|
2279
2284
|
const options = { ...DEFAULT_SUPPLIERS, ...supplierOptions };
|
|
2280
|
-
return (jsx(FormShell, { ariaLabel: "Add loyalty program", className: className, disabled: disabled, onCancel: onCancel, onSubmit: onSubmit, showActions: showActions, values: formValues, children: jsxs("div", { className: styles$
|
|
2285
|
+
return (jsx(FormShell, { ariaLabel: "Add loyalty program", className: className, disabled: disabled, onCancel: onCancel, onSubmit: onSubmit, showActions: showActions, values: formValues, children: jsxs("div", { className: styles$h.stack, children: [jsx(Select, { label: "Type", options: ['Air', 'Car', 'Hotel'].map((type) => ({ label: type, value: type })), value: formValues.type, onChange: (event) => updateValues({ type: event.target.value, supplier: '' }), disabled: disabled, fullWidth: true }), jsx(Select, { label: "Company *", placeholder: "Select a company", options: options[formValues.type] ?? [], value: formValues.supplier, onChange: (event) => updateValues({ supplier: event.target.value }), required: true, disabled: disabled, fullWidth: true }), jsx(Input, { label: "Program Number *", value: formValues.accountNumber, onChange: (event) => updateValues({ accountNumber: event.target.value }), required: true, disabled: disabled, fullWidth: true })] }) }));
|
|
2281
2286
|
};
|
|
2282
2287
|
const EMPTY_ROSTER_MEMBER = {
|
|
2283
2288
|
portalUserId: '',
|
|
@@ -2319,12 +2324,12 @@ const localDateString = (date) => {
|
|
|
2319
2324
|
};
|
|
2320
2325
|
const SectionBadge = ({ complete, optional, label }) => {
|
|
2321
2326
|
if (optional)
|
|
2322
|
-
return jsx("span", { className: `${styles$
|
|
2327
|
+
return jsx("span", { className: `${styles$h.badge} ${styles$h.optionalBadge}`, children: "Optional" });
|
|
2323
2328
|
if (complete)
|
|
2324
|
-
return jsxs("span", { className: `${styles$
|
|
2325
|
-
return jsxs("span", { className: `${styles$
|
|
2329
|
+
return jsxs("span", { className: `${styles$h.badge} ${styles$h.completeBadge}`, children: [jsx(CheckIcon$2, { size: 12 }), "Complete"] });
|
|
2330
|
+
return jsxs("span", { className: `${styles$h.badge} ${styles$h.incompleteBadge}`, children: [jsx(WarningIcon$1, { size: 12 }), label ?? 'Incomplete'] });
|
|
2326
2331
|
};
|
|
2327
|
-
const SectionCard = ({ icon, title, subtitle, badge, blue = false, children, }) => (jsxs("section", { className: `${styles$
|
|
2332
|
+
const SectionCard = ({ icon, title, subtitle, badge, blue = false, children, }) => (jsxs("section", { className: `${styles$h.sectionCard} ${blue ? styles$h.blueSection : ''}`, children: [jsxs("div", { className: styles$h.sectionHeader, children: [jsx("div", { className: styles$h.sectionIcon, children: icon }), jsxs("div", { className: styles$h.sectionHeading, children: [jsx("h3", { children: title }), jsx("p", { children: subtitle })] }), badge] }), children] }));
|
|
2328
2333
|
const TeamRosterMemberForm = ({ mode = 'Add', values, initialValues, onChange, onSubmit, onCancel, showActions = true, disabled = false, className, portalUsers = [], airlineOptions = DEFAULT_AIRLINES, travelerTypeOptions = DEFAULT_TRAVELER_TYPES, }) => {
|
|
2329
2334
|
const [formValues, updateValues] = useManagedValues(values, { ...EMPTY_ROSTER_MEMBER, ...initialValues }, onChange);
|
|
2330
2335
|
const minBirthDate = new Date();
|
|
@@ -2338,10 +2343,10 @@ const TeamRosterMemberForm = ({ mode = 'Add', values, initialValues, onChange, o
|
|
|
2338
2343
|
const portalUserId = event.target.value;
|
|
2339
2344
|
const selectedUser = portalUsers.find((option) => String(option.value) === portalUserId);
|
|
2340
2345
|
updateValues({ ...selectedUser?.traveler, portalUserId });
|
|
2341
|
-
}, disabled: disabled, fullWidth: true }) })), jsxs(SectionCard, { icon: jsx(UserIcon, { size: 20 }), title: "Identity", subtitle: "Name as it appears on government ID", badge: jsx(SectionBadge, { complete: identityComplete }), children: [jsxs("div", { className: styles$
|
|
2346
|
+
}, disabled: disabled, fullWidth: true }) })), jsxs(SectionCard, { icon: jsx(UserIcon, { size: 20 }), title: "Identity", subtitle: "Name as it appears on government ID", badge: jsx(SectionBadge, { complete: identityComplete }), children: [jsxs("div", { className: styles$h.threeColumnGrid, children: [jsx(Input, { label: "First Name *", value: formValues.firstName, onChange: (event) => updateValues({ firstName: event.target.value }), required: true, disabled: disabled, fullWidth: true }), jsxs("div", { className: styles$h.middleNameField, children: [jsxs("div", { className: styles$h.fieldHeader, children: [jsx("label", { htmlFor: "team-middle-name", children: "Middle Name" }), jsx(Checkbox, { label: "None", size: "sm", checked: formValues.noMiddleName, onChange: (event) => updateValues({
|
|
2342
2347
|
noMiddleName: event.target.checked,
|
|
2343
2348
|
middleName: event.target.checked ? '' : formValues.middleName,
|
|
2344
|
-
}), disabled: disabled })] }), jsx(Input, { id: "team-middle-name", "aria-label": "Middle Name", placeholder: formValues.noMiddleName ? 'None' : '', value: formValues.middleName, onChange: (event) => updateValues({ middleName: event.target.value }), required: !formValues.noMiddleName, disabled: disabled || formValues.noMiddleName, fullWidth: true })] }), jsx(Input, { label: "Last Name *", value: formValues.lastName, onChange: (event) => updateValues({ lastName: event.target.value }), required: true, disabled: disabled, fullWidth: true })] }), jsx(Select, { label: "Traveler Type *", placeholder: "Select traveler type", options: travelerTypeOptions, value: formValues.travelerType, onChange: (event) => updateValues({ travelerType: event.target.value }), required: true, disabled: disabled, fullWidth: true })] }), jsx(SectionCard, { icon: jsx(LockIcon$1, { size: 20 }), title: "Secure Flight", subtitle: "TSA-required for every air booking", badge: jsx(SectionBadge, { complete: secureFlightComplete, label: !formValues.weight || Number(formValues.weight) < 1 ? 'Add weight' : undefined }), children: jsxs("div", { className: styles$
|
|
2349
|
+
}), disabled: disabled })] }), jsx(Input, { id: "team-middle-name", "aria-label": "Middle Name", placeholder: formValues.noMiddleName ? 'None' : '', value: formValues.middleName, onChange: (event) => updateValues({ middleName: event.target.value }), required: !formValues.noMiddleName, disabled: disabled || formValues.noMiddleName, fullWidth: true })] }), jsx(Input, { label: "Last Name *", value: formValues.lastName, onChange: (event) => updateValues({ lastName: event.target.value }), required: true, disabled: disabled, fullWidth: true })] }), jsx(Select, { label: "Traveler Type *", placeholder: "Select traveler type", options: travelerTypeOptions, value: formValues.travelerType, onChange: (event) => updateValues({ travelerType: event.target.value }), required: true, disabled: disabled, fullWidth: true })] }), jsx(SectionCard, { icon: jsx(LockIcon$1, { size: 20 }), title: "Secure Flight", subtitle: "TSA-required for every air booking", badge: jsx(SectionBadge, { complete: secureFlightComplete, label: !formValues.weight || Number(formValues.weight) < 1 ? 'Add weight' : undefined }), children: jsxs("div", { className: styles$h.threeColumnGrid, children: [jsx(Input, { label: "Date of Birth *", type: "date", min: localDateString(minBirthDate), max: localDateString(new Date()), value: formValues.birthDate, onChange: (event) => updateValues({ birthDate: event.target.value }), required: true, disabled: disabled, fullWidth: true }), jsx(Select, { label: "Gender *", placeholder: "Select gender", options: ['Male', 'Female', 'Unspecified (X)'].map((label) => ({ label, value: label })), value: formValues.gender, onChange: (event) => updateValues({ gender: event.target.value }), required: true, disabled: disabled, fullWidth: true }), jsx(Input, { label: "Weight (lbs) *", type: "number", min: "1", value: formValues.weight, onChange: (event) => updateValues({ weight: numericValue$1(event.target.value) }), required: true, disabled: disabled, fullWidth: true }), jsx(Input, { label: "Passport No.", placeholder: "Add for intl. travel", value: formValues.passportNumber, onChange: (event) => updateValues({ passportNumber: event.target.value.toUpperCase() }), disabled: disabled, fullWidth: true }), jsx(Input, { label: "Known Traveler No.", placeholder: "KTN", value: formValues.knownTravelerNumber, onChange: (event) => updateValues({ knownTravelerNumber: event.target.value.toUpperCase() }), disabled: disabled, fullWidth: true }), jsx(Input, { label: "DHS Redress No.", placeholder: "Add if issued", value: formValues.dhsRedressNumber, onChange: (event) => updateValues({ dhsRedressNumber: event.target.value.toUpperCase() }), disabled: disabled, fullWidth: true })] }) }), mode === 'Add' && (jsx(SectionCard, { icon: jsx(PlaneIcon$3, { size: 20 }), title: "Frequent Flyer", subtitle: "Airline loyalty program details", badge: jsx(SectionBadge, { optional: true }), children: jsxs("div", { className: styles$h.twoColumnGrid, children: [jsx(Select, { label: "Airline", placeholder: "Select airline", options: airlineOptions, value: formValues.airline, onChange: (event) => updateValues({ airline: event.target.value }), disabled: disabled, fullWidth: true }), jsx(Input, { label: "Frequent Flyer Number", value: formValues.frequentFlyerNumber, onChange: (event) => updateValues({ frequentFlyerNumber: event.target.value }), disabled: disabled, fullWidth: true })] }) })), jsx(SectionCard, { icon: jsx(InfoIcon$1, { size: 20 }), title: "Special Requests", subtitle: "Dietary, seating, accessibility, rooming", badge: jsx(SectionBadge, { optional: true }), children: jsx(Textarea, { "aria-label": "Special Requests", placeholder: "Add anything the travel desk should know\u2026", value: formValues.specialRequests, onChange: (event) => updateValues({ specialRequests: event.target.value }), rows: 3, disabled: disabled, fullWidth: true }) })] }));
|
|
2345
2350
|
};
|
|
2346
2351
|
const IMPORT_COPY = {
|
|
2347
2352
|
equipment: {
|
|
@@ -2373,14 +2378,14 @@ const IMPORT_COPY = {
|
|
|
2373
2378
|
const TeamImportForm = ({ kind, onSubmit, onCancel, disabled = false, className = '' }) => {
|
|
2374
2379
|
const [file, setFile] = useState(null);
|
|
2375
2380
|
const copy = IMPORT_COPY[kind];
|
|
2376
|
-
return (jsxs("form", { "aria-label": `Import ${kind}`, className: `${styles$
|
|
2381
|
+
return (jsxs("form", { "aria-label": `Import ${kind}`, className: `${styles$h.form} ${className}`, onSubmit: (event) => {
|
|
2377
2382
|
event.preventDefault();
|
|
2378
2383
|
if (file)
|
|
2379
2384
|
onSubmit?.(file);
|
|
2380
|
-
}, children: [jsx("ol", { className: styles$
|
|
2385
|
+
}, children: [jsx("ol", { className: styles$h.instructions, children: copy.instructions.map((instruction, index) => jsxs("li", { children: [index + 1, ". ", instruction] }, instruction)) }), jsx("a", { className: styles$h.sampleLink, href: `/${copy.sample}`, download: true, children: copy.sample }), jsxs("label", { className: styles$h.fileField, children: [jsx(UploadIcon, { size: 24 }), jsx("span", { children: file?.name ?? 'Choose an Excel spreadsheet' }), jsx("input", { "aria-label": "Spreadsheet file", type: "file", accept: ".xlsx,.xls", onChange: (event) => setFile(event.target.files?.[0] ?? null), required: true, disabled: disabled })] }), jsxs("div", { className: styles$h.actions, children: [jsx(Button, { type: "button", variant: "secondary", onClick: onCancel, disabled: disabled, children: "Cancel" }), jsx(Button, { type: "submit", disabled: disabled || !file, children: "Import" })] })] }));
|
|
2381
2386
|
};
|
|
2382
2387
|
|
|
2383
|
-
var styles$
|
|
2388
|
+
var styles$g = {"grid":"TravelSummaryMetrics-module_grid__RqAU9"};
|
|
2384
2389
|
|
|
2385
2390
|
const numericValue = (value) => {
|
|
2386
2391
|
if (value === undefined || value === null || value === '')
|
|
@@ -2398,25 +2403,25 @@ const formatCompactTripCost = (value) => {
|
|
|
2398
2403
|
};
|
|
2399
2404
|
const TravelSummaryMetrics = ({ tripsTraveled, remainingTrips, seasonTripCosts, seasonLabel, overdueActions, onOverdueActionsClick, className = '', }) => {
|
|
2400
2405
|
const overdueCount = numericValue(overdueActions) ?? 0;
|
|
2401
|
-
return (jsxs("div", { className: [styles$
|
|
2406
|
+
return (jsxs("div", { className: [styles$g.grid, className].filter(Boolean).join(' '), children: [jsx(Metric, { value: tripsTraveled, label: "Trips Travelled" }), jsx(Metric, { value: remainingTrips, label: "Remaining Trips" }), jsx(Metric, { value: formatCompactTripCost(seasonTripCosts), label: `${seasonLabel} Trip Costs`, prefix: "$" }), jsx(Metric, { value: overdueActions, label: "Overdue Actions", warning: overdueCount > 0, dark: true, onClick: onOverdueActionsClick })] }));
|
|
2402
2407
|
};
|
|
2403
2408
|
|
|
2404
|
-
var styles$
|
|
2409
|
+
var styles$f = {"form":"TravelerForm-module_form__wgss7","loading":"TravelerForm-module_loading__u38gT","header":"TravelerForm-module_header__X6v0S","title":"TravelerForm-module_title__pDabg","subtitle":"TravelerForm-module_subtitle__wArO7","content":"TravelerForm-module_content__NDu--","sections":"TravelerForm-module_sections__rnhZw","section":"TravelerForm-module_section__ukKVw","sectionTitle":"TravelerForm-module_sectionTitle__rtWV2","sectionContent":"TravelerForm-module_sectionContent__HPqkN","footer":"TravelerForm-module_footer__qQM1J"};
|
|
2405
2410
|
|
|
2406
2411
|
/**
|
|
2407
2412
|
* TravelerForm - Form layout for editing traveler/roster member details
|
|
2408
2413
|
*/
|
|
2409
2414
|
const TravelerForm = ({ values = {}, title, subtitle, children, renderNameSection, renderDetailsSection, renderPreferencesSection, footer, isLoading = false, className = '', }) => {
|
|
2410
2415
|
const formClasses = [
|
|
2411
|
-
styles$
|
|
2412
|
-
isLoading ? styles$
|
|
2416
|
+
styles$f.form,
|
|
2417
|
+
isLoading ? styles$f.loading : '',
|
|
2413
2418
|
className,
|
|
2414
2419
|
].filter(Boolean).join(' ');
|
|
2415
|
-
return (jsxs("div", { className: formClasses, children: [(title || subtitle) && (jsxs("div", { className: styles$
|
|
2420
|
+
return (jsxs("div", { className: formClasses, children: [(title || subtitle) && (jsxs("div", { className: styles$f.header, children: [title && jsx("h2", { className: styles$f.title, children: title }), subtitle && jsx("p", { className: styles$f.subtitle, children: subtitle })] })), children ? (jsx("div", { className: styles$f.content, children: children })) : (jsxs("div", { className: styles$f.sections, children: [renderNameSection && (jsxs("div", { className: styles$f.section, children: [jsx("h3", { className: styles$f.sectionTitle, children: "Name" }), jsx("div", { className: styles$f.sectionContent, children: renderNameSection(values) })] })), renderDetailsSection && (jsxs("div", { className: styles$f.section, children: [jsx("h3", { className: styles$f.sectionTitle, children: "Details" }), jsx("div", { className: styles$f.sectionContent, children: renderDetailsSection(values) })] })), renderPreferencesSection && (jsxs("div", { className: styles$f.section, children: [jsx("h3", { className: styles$f.sectionTitle, children: "Travel Preferences" }), jsx("div", { className: styles$f.sectionContent, children: renderPreferencesSection(values) })] }))] })), footer && (jsx("div", { className: styles$f.footer, children: footer }))] }));
|
|
2416
2421
|
};
|
|
2417
2422
|
TravelerForm.displayName = 'TravelerForm';
|
|
2418
2423
|
|
|
2419
|
-
var styles$
|
|
2424
|
+
var styles$e = {"table":"TripTable-module_table__28HM1","header":"TripTable-module_header__VNQyG","serviceHeader":"TripTable-module_serviceHeader__AXqua","requestedHeader":"TripTable-module_requestedHeader__7RhgA","row":"TripTable-module_row__EIDoN","serviceRow":"TripTable-module_serviceRow__jhL2v","requestedRow":"TripTable-module_requestedRow__Sofhd","compact":"TripTable-module_compact__QiKWg","textMuted":"TripTable-module_textMuted__Wl7pk","pnrLink":"TripTable-module_pnrLink__XmIdV","vendorCode":"TripTable-module_vendorCode__mfnDQ","typesCell":"TripTable-module_typesCell__u7wYw","serviceCell":"TripTable-module_serviceCell__8PcQl","servicePlaceholder":"TripTable-module_servicePlaceholder__BEBJ7","viewCol":"TripTable-module_viewCol__LLt-7","viewLink":"TripTable-module_viewLink__lr6Rf","travelerCell":"TripTable-module_travelerCell__8X804","moreCount":"TripTable-module_moreCount__ZoYs5","requestedByCell":"TripTable-module_requestedByCell__6ARM-","submittedDate":"TripTable-module_submittedDate__FBqEI","empty":"TripTable-module_empty__Nzic2","emptyTitle":"TripTable-module_emptyTitle__QkWAx","emptyText":"TripTable-module_emptyText__KPP9Q"};
|
|
2420
2425
|
|
|
2421
2426
|
// TravelerCell component
|
|
2422
2427
|
const TravelerCell = ({ names }) => {
|
|
@@ -2424,7 +2429,7 @@ const TravelerCell = ({ names }) => {
|
|
|
2424
2429
|
return jsx("span", { children: "\u2014" });
|
|
2425
2430
|
if (names.length === 1)
|
|
2426
2431
|
return jsx("span", { children: names[0] });
|
|
2427
|
-
return (jsxs("span", { className: styles$
|
|
2432
|
+
return (jsxs("span", { className: styles$e.travelerCell, children: [jsx("span", { children: names[0] }), jsxs("span", { className: styles$e.moreCount, children: ["+", names.length - 1] })] }));
|
|
2428
2433
|
};
|
|
2429
2434
|
// Chevron icon
|
|
2430
2435
|
const ChevronRight$1 = ({ size = 20 }) => (jsx("svg", { width: size, height: size, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2.5", children: jsx("polyline", { points: "9 18 15 12 9 6" }) }));
|
|
@@ -2444,33 +2449,33 @@ const TripTable = ({ trips, variant = 'current', density = 'comfortable', vendor
|
|
|
2444
2449
|
};
|
|
2445
2450
|
return statusMap[status] || status.toLowerCase();
|
|
2446
2451
|
};
|
|
2447
|
-
return (jsxs("div", { className: `${styles$
|
|
2452
|
+
return (jsxs("div", { className: `${styles$e.table} ${className || ''}`, children: [jsx("div", { className: `${styles$e.header} ${isRequested ? styles$e.requestedHeader : ''} ${useServiceColumn ? styles$e.serviceHeader : ''}`, children: isRequested ? (jsxs(Fragment, { children: [jsx("div", { children: "Request ID" }), jsx("div", { children: "Traveler(s)" }), jsx("div", { children: "Trip Type" }), jsx("div", { children: "Requested By" }), jsx("div", { className: styles$e.viewCol, children: "View" })] })) : (jsxs(Fragment, { children: [jsx("div", { children: "Traveler" }), jsx("div", { children: "Sport" }), jsx("div", { children: "PNR" }), useServiceColumn ? (jsxs(Fragment, { children: [jsx("div", { children: "Service" }), jsx("div", { children: "Itinerary" })] })) : (jsxs(Fragment, { children: [jsx("div", { children: "Vendor" }), jsx("div", { children: "Itinerary" }), jsx("div", { children: "Types" })] })), jsx("div", { children: "Travel Dates" }), jsx("div", { children: "Status" }), jsx("div", {})] })) }), trips.length === 0 ? (jsxs("div", { className: styles$e.empty, children: [jsx("div", { className: styles$e.emptyTitle, children: isRequested ? 'No Requested Trips' : 'No Trips Found' }), jsx("div", { className: styles$e.emptyText, children: emptyMessage || (isRequested
|
|
2448
2453
|
? 'Travel requests submitted to STM will appear here until an agent books them.'
|
|
2449
2454
|
: 'Try clearing your filters or widening the date range.') })] })) : (trips.map((trip, index) => (jsx("div", { className: `
|
|
2450
|
-
${styles$
|
|
2451
|
-
${isRequested ? styles$
|
|
2452
|
-
${useServiceColumn ? styles$
|
|
2453
|
-
${isCompact ? styles$
|
|
2454
|
-
`, onClick: () => onViewTrip?.(trip.pnr || trip.reqId || trip.id), children: isRequested ? (jsxs(Fragment, { children: [jsx("div", { children: jsx("a", { href: "#", className: styles$
|
|
2455
|
+
${styles$e.row}
|
|
2456
|
+
${isRequested ? styles$e.requestedRow : ''}
|
|
2457
|
+
${useServiceColumn ? styles$e.serviceRow : ''}
|
|
2458
|
+
${isCompact ? styles$e.compact : ''}
|
|
2459
|
+
`, onClick: () => onViewTrip?.(trip.pnr || trip.reqId || trip.id), children: isRequested ? (jsxs(Fragment, { children: [jsx("div", { children: jsx("a", { href: "#", className: styles$e.pnrLink, onClick: (e) => {
|
|
2455
2460
|
e.preventDefault();
|
|
2456
2461
|
e.stopPropagation();
|
|
2457
2462
|
onViewTrip?.(trip.reqId || trip.id);
|
|
2458
|
-
}, children: trip.reqId }) }), jsx("div", { className: styles$
|
|
2463
|
+
}, children: trip.reqId }) }), jsx("div", { className: styles$e.textMuted, children: jsx(TravelerCell, { names: trip.travelers }) }), jsx("div", { className: styles$e.typesCell, children: trip.types.map((t, ti) => (jsx(TypeIcon, { type: t, size: isCompact ? 14 : 16 }, ti))) }), jsxs("div", { className: styles$e.requestedByCell, children: [jsx("div", { className: styles$e.textMuted, children: trip.requestedBy }), trip.submitted && (jsxs("div", { className: styles$e.submittedDate, children: ["Submitted ", trip.submitted] }))] }), jsx("div", { className: styles$e.viewCol, children: jsx("a", { href: "#", className: styles$e.viewLink, onClick: (e) => {
|
|
2459
2464
|
e.preventDefault();
|
|
2460
2465
|
e.stopPropagation();
|
|
2461
2466
|
onViewTrip?.(trip.reqId || trip.id);
|
|
2462
|
-
}, title: "View request detail", children: jsx(ChevronRight$1, {}) }) })] })) : (jsxs(Fragment, { children: [jsx("div", { className: styles$
|
|
2467
|
+
}, title: "View request detail", children: jsx(ChevronRight$1, {}) }) })] })) : (jsxs(Fragment, { children: [jsx("div", { className: styles$e.textMuted, children: jsx(TravelerCell, { names: trip.travelers }) }), jsx("div", { className: styles$e.textMuted, children: trip.sport || '—' }), jsx("div", { children: jsx("a", { href: "#", className: styles$e.pnrLink, onClick: (e) => {
|
|
2463
2468
|
e.preventDefault();
|
|
2464
2469
|
e.stopPropagation();
|
|
2465
2470
|
onViewTrip?.(trip.pnr || trip.id);
|
|
2466
|
-
}, children: trip.pnr }) }), useServiceColumn ? (jsxs(Fragment, { children: [jsx("div", { className: styles$
|
|
2471
|
+
}, children: trip.pnr }) }), useServiceColumn ? (jsxs(Fragment, { children: [jsx("div", { className: styles$e.serviceCell, children: ['A', 'H', 'C'].map(slot => (trip.types.includes(slot) ? (jsx(TravelServiceIcon, { type: slot, vendor: slot === 'A' ? trip.vendor : undefined, mode: vendorMode, size: serviceIconSize, multi: trip.multiSegments?.includes(slot) }, slot)) : (jsx("span", { className: styles$e.servicePlaceholder, style: { width: serviceIconSize, height: serviceIconSize } }, slot)))) }), jsx("div", { className: styles$e.textMuted, children: trip.itinerary || '—' })] })) : (jsxs(Fragment, { children: [jsx("div", { children: trip.vendor && vendorMode === 'icon' ? (jsx(TravelServiceIcon, { type: "A", vendor: trip.vendor, mode: "icon", size: 24 })) : (jsx("span", { className: styles$e.vendorCode, children: trip.vendor || '—' })) }), jsx("div", { className: styles$e.textMuted, children: trip.itinerary || '—' }), jsx("div", { className: styles$e.typesCell, children: trip.types.map((t, ti) => (jsx(TypeIcon, { type: t, size: isCompact ? 14 : 16 }, ti))) })] })), jsx("div", { className: styles$e.textMuted, children: trip.dates }), jsx("div", { children: jsx(StatusBadge, { status: mapStatus(trip.status) }) }), jsx("div", { className: styles$e.viewCol, children: jsx("a", { href: "#", className: styles$e.viewLink, onClick: (e) => {
|
|
2467
2472
|
e.preventDefault();
|
|
2468
2473
|
e.stopPropagation();
|
|
2469
2474
|
onViewTrip?.(trip.pnr || trip.id);
|
|
2470
2475
|
}, title: "View itinerary", children: jsx(ChevronRight$1, {}) }) })] })) }, trip.id || trip.pnr || trip.reqId || index))))] }));
|
|
2471
2476
|
};
|
|
2472
2477
|
|
|
2473
|
-
var styles$
|
|
2478
|
+
var styles$d = {"page":"AdministrationPage-module_page__48Run","header":"AdministrationPage-module_header__HNQnE","tabs":"AdministrationPage-module_tabs__QPvcD","tab":"AdministrationPage-module_tab__bNaU8","activeTab":"AdministrationPage-module_activeTab__B-e3a","cards":"AdministrationPage-module_cards__nISnI","card":"AdministrationPage-module_card__6r45y","cardIcon":"AdministrationPage-module_cardIcon__GTb3t","cardCopy":"AdministrationPage-module_cardCopy__o9pWk","cardTitle":"AdministrationPage-module_cardTitle__56qEV","cardDescription":"AdministrationPage-module_cardDescription__66e9F","comingSoon":"AdministrationPage-module_comingSoon__LSm-x","chevron":"AdministrationPage-module_chevron__d9RPb"};
|
|
2474
2479
|
|
|
2475
2480
|
const DEFAULT_CARDS = [
|
|
2476
2481
|
{
|
|
@@ -2487,9 +2492,9 @@ const DEFAULT_CARDS = [
|
|
|
2487
2492
|
},
|
|
2488
2493
|
];
|
|
2489
2494
|
/** Hub administration shell and system-card index. */
|
|
2490
|
-
const AdministrationPage = ({ activeTab = 'system', onTabChange, cards = DEFAULT_CARDS, onCardClick, children, className = '', }) => (jsxs("div", { className: [styles$
|
|
2495
|
+
const AdministrationPage = ({ activeTab = 'system', onTabChange, cards = DEFAULT_CARDS, onCardClick, children, className = '', }) => (jsxs("div", { className: [styles$d.page, className].filter(Boolean).join(' '), children: [jsx("header", { className: styles$d.header, children: jsx("h1", { children: "Administration\u00A0" }) }), jsx("div", { className: styles$d.tabs, role: "tablist", "aria-label": "Administration sections", children: ['system', 'client'].map((tab) => (jsx("button", { type: "button", role: "tab", "aria-selected": activeTab === tab, className: [styles$d.tab, activeTab === tab ? styles$d.activeTab : ''].filter(Boolean).join(' '), onClick: () => onTabChange?.(tab), children: tab === 'system' ? 'System' : 'Client' }, tab))) }), children ?? (activeTab === 'system' ? (jsx("div", { className: styles$d.cards, children: cards.map((card) => (jsxs("button", { type: "button", className: styles$d.card, onClick: () => onCardClick?.(card), children: [jsx("span", { className: styles$d.cardIcon, children: card.icon }), jsxs("span", { className: styles$d.cardCopy, children: [jsx("span", { className: styles$d.cardTitle, children: card.title }), jsx("span", { className: styles$d.cardDescription, children: card.description })] }), jsx(ChevronRightIcon$1, { className: styles$d.chevron, size: 14 })] }, card.key))) })) : (jsx("p", { className: styles$d.comingSoon, children: "Client administration settings coming soon." })))] }));
|
|
2491
2496
|
|
|
2492
|
-
var styles$
|
|
2497
|
+
var styles$c = {"page":"CharterManifestPage-module_page__4UnP4","header":"CharterManifestPage-module_header__7t4UK","headerRow":"CharterManifestPage-module_headerRow__am-n5","back":"CharterManifestPage-module_back__mkIGo","headerActions":"CharterManifestPage-module_headerActions__mRD0H","status":"CharterManifestPage-module_status__cH7xC","statusLocked":"CharterManifestPage-module_statusLocked__HYrMe","dateRow":"CharterManifestPage-module_dateRow__vK3mC","metaRow":"CharterManifestPage-module_metaRow__At8EU","dateLine":"CharterManifestPage-module_dateLine__03Ffw","layout":"CharterManifestPage-module_layout__No8EZ","rail":"CharterManifestPage-module_rail__-vvQH","eyebrow":"CharterManifestPage-module_eyebrow__7xT-c","scopeList":"CharterManifestPage-module_scopeList__dFBWN","scope":"CharterManifestPage-module_scope__gLjhn","activeScope":"CharterManifestPage-module_activeScope__3-l04","carrierCard":"CharterManifestPage-module_carrierCard__CG8-U","capacityCard":"CharterManifestPage-module_capacityCard__LkwXi","finalize":"CharterManifestPage-module_finalize__zmVtB","main":"CharterManifestPage-module_main__RtVqB","viewRow":"CharterManifestPage-module_viewRow__5MIfn","lockedMessage":"CharterManifestPage-module_lockedMessage__dtFNK","tableActions":"CharterManifestPage-module_tableActions__yq0AD","sortToggle":"CharterManifestPage-module_sortToggle__QQbqt","activeSort":"CharterManifestPage-module_activeSort__IpZJr","tableWrap":"CharterManifestPage-module_tableWrap__WbU-G","empty":"CharterManifestPage-module_empty__MH8nG","typeTag":"CharterManifestPage-module_typeTag__WqQDj","typePlayer":"CharterManifestPage-module_typePlayer__B6VjC","typeCoach":"CharterManifestPage-module_typeCoach__X4kV4","typeMedical":"CharterManifestPage-module_typeMedical__N7k22","remove":"CharterManifestPage-module_remove__8R1PT","finalizeActions":"CharterManifestPage-module_finalizeActions__3Gabv"};
|
|
2493
2498
|
|
|
2494
2499
|
const TYPE_ORDER = ['Player', 'Coach', 'Staff', 'Medical', 'Support', 'Admin'];
|
|
2495
2500
|
const formatDate = (value) => {
|
|
@@ -2500,10 +2505,10 @@ const formatDate = (value) => {
|
|
|
2500
2505
|
return value;
|
|
2501
2506
|
return date.toLocaleDateString(undefined, { weekday: 'short', month: 'short', day: 'numeric', year: 'numeric' });
|
|
2502
2507
|
};
|
|
2503
|
-
const TypeTag = ({ type }) => (jsx("span", { className: [styles$
|
|
2508
|
+
const TypeTag = ({ type }) => (jsx("span", { className: [styles$c.typeTag, styles$c[`type${type}`] ?? ''].filter(Boolean).join(' '), children: type }));
|
|
2504
2509
|
const StatusPill = ({ sendState, locked }) => {
|
|
2505
2510
|
const label = locked ? 'Final sent · Locked' : sendState === 'initial-sent' ? 'Initial sent' : sendState === 'final-sent' ? 'Final sent' : 'Not sent';
|
|
2506
|
-
return jsx("span", { className: [styles$
|
|
2511
|
+
return jsx("span", { className: [styles$c.status, locked ? styles$c.statusLocked : ''].filter(Boolean).join(' '), children: label });
|
|
2507
2512
|
};
|
|
2508
2513
|
/** Stateless, service-free rendering of Hub's charter manifest page. */
|
|
2509
2514
|
const CharterManifestPage = ({ tripName, travelStartDate, travelEndDate, seats, payloadLimit, passengerWeight, cargoWeight, carrierName = 'No carrier selected', carrierNote = 'Select a carrier to configure manifest fields.', passengers = [], equipment = [], segments = [], locked = false, sendState = 'none', onBack, onGenerateFile, onChangeCarrier, onSplitSegments, onAddPassengers, onAddEquipment, onRemovePassenger, onRemoveEquipment, onSendInitial, onSendFinal, onUndoInitial, className = '', }) => {
|
|
@@ -2520,35 +2525,35 @@ const CharterManifestPage = ({ tripName, travelStartDate, travelEndDate, seats,
|
|
|
2520
2525
|
}
|
|
2521
2526
|
return a.lastName.localeCompare(b.lastName);
|
|
2522
2527
|
}), [passengers, sort]);
|
|
2523
|
-
return (jsxs("div", { className: [styles$
|
|
2528
|
+
return (jsxs("div", { className: [styles$c.page, className].filter(Boolean).join(' '), "data-screen-label": "Charter Trip Manifest", children: [jsxs("header", { className: styles$c.header, children: [jsxs("div", { className: styles$c.headerRow, children: [jsx("button", { type: "button", "aria-label": "Back", className: styles$c.back, onClick: onBack, children: jsx(ChevronLeftIcon, { size: 28 }) }), jsxs("h1", { children: [jsx("strong", { children: "Manifest" }), jsx(ChevronRightIcon$1, { size: 24 }), jsx("span", { children: tripName })] }), jsxs("div", { className: styles$c.headerActions, children: [jsx(StatusPill, { sendState: sendState, locked: locked }), jsx(Button, { variant: "outline", leftIcon: jsx(DocumentIcon, { size: 16 }), disabled: carrierName === 'No carrier selected', onClick: onGenerateFile, children: "Generate File" })] })] }), (travelStartDate || travelEndDate) && (jsxs("div", { className: styles$c.dateRow, children: [jsx("span", { children: formatDate(travelStartDate) }), jsx("span", { className: styles$c.dateLine, children: "\u25B6" }), jsx("span", { children: formatDate(travelEndDate) })] })), jsxs("div", { className: styles$c.metaRow, children: [jsxs("span", { children: [jsx(PlaneIcon$3, { size: 16 }), seats, " seats"] }), jsxs("span", { children: [jsx(CubeIcon, { size: 16 }), "Payload limit ", payloadLimit.toLocaleString(), " lb"] })] })] }), jsxs("div", { className: styles$c.layout, children: [jsxs("aside", { className: styles$c.rail, children: [jsxs("div", { children: [jsx("div", { className: styles$c.eyebrow, children: "Flight Manifest" }), jsx("div", { className: styles$c.scopeList, children: [{ id: 'all', label: 'Full Trip', detail: 'All flight segments' }, ...segments].map((item) => (jsxs("button", { type: "button", className: [styles$c.scope, scope === item.id ? styles$c.activeScope : ''].filter(Boolean).join(' '), onClick: () => setScope(item.id), children: [jsx("strong", { children: item.label }), jsx("span", { children: item.detail })] }, item.id))) })] }), segments.length > 0 && (jsx(Button, { variant: "outline", size: "sm", disabled: locked, onClick: onSplitSegments, children: "Split by Segment" })), jsxs("div", { className: styles$c.carrierCard, children: [jsx("div", { className: styles$c.eyebrow, children: "Carrier" }), jsx("strong", { children: carrierName }), jsx("p", { children: carrierNote }), jsx(Button, { variant: "outline", size: "sm", fullWidth: true, disabled: locked, leftIcon: jsx(SettingsIcon, { size: 15 }), onClick: onChangeCarrier, children: "Change Carrier" })] })] }), jsxs("main", { className: styles$c.main, children: [jsx("section", { className: styles$c.capacityCard, children: jsx(ManifestCapacityStats, { paxCount: passengers.length, seats: seats, paxWeight: passengerWeight, cargoWeight: cargoWeight, payloadLimit: payloadLimit }) }), jsxs("div", { className: styles$c.viewRow, children: [jsx(ManifestViewToggle, { view: view, onView: setView, paxCount: passengers.length, eqCount: equipment.length, locked: locked }), locked && jsx("span", { className: styles$c.lockedMessage, children: "Locked \u2014 coordinate any changes directly with the carrier." })] }), view === 'passengers' ? (jsxs("section", { children: [!locked && (jsxs("div", { className: styles$c.tableActions, children: [jsxs("strong", { children: [passengers.length, " Passengers"] }), jsxs("div", { children: [jsx("span", { children: "Order by" }), jsx("span", { className: styles$c.sortToggle, children: ['name', 'type'].map((option) => (jsx("button", { type: "button", className: sort === option ? styles$c.activeSort : '', onClick: () => setSort(option), children: option }, option))) }), jsx(Button, { size: "sm", leftIcon: jsx(PlusIcon$2, { size: 15 }), onClick: onAddPassengers, children: "Add Passengers" })] })] })), jsx("div", { className: styles$c.tableWrap, children: jsxs("table", { children: [jsx("thead", { children: jsxs("tr", { children: [jsx("th", { children: "#" }), jsx("th", { children: "Passenger" }), jsx("th", { children: "Type" }), jsx("th", { children: "TSA Screening" }), jsx("th", { children: "Personal" }), jsx("th", { children: "Carry-On" }), jsx("th", { children: "Checked" }), jsx("th", { children: "Seat" }), jsx("th", {})] }) }), jsxs("tbody", { children: [!sortedPassengers.length && jsx("tr", { children: jsx("td", { colSpan: 9, className: styles$c.empty, children: "No passengers on this manifest yet. Add passengers from the master list." }) }), sortedPassengers.map((passenger, index) => (jsxs("tr", { children: [jsx("td", { children: index + 1 }), jsxs("td", { children: [jsx("strong", { children: passenger.lastName }), jsxs("span", { children: [", ", passenger.firstName] })] }), jsx("td", { children: jsx(TypeTag, { type: passenger.travelerType }) }), jsx("td", { children: passenger.screeningType || '—' }), jsxs("td", { children: [passenger.personalWeight ?? 0, " lb"] }), jsxs("td", { children: [passenger.carryOnWeight ?? 0, " lb"] }), jsxs("td", { children: [passenger.checkedWeight ?? 0, " lb"] }), jsx("td", { children: passenger.seatAssignment || '—' }), jsx("td", { children: !locked && jsx("button", { type: "button", "aria-label": `Remove ${passenger.firstName} ${passenger.lastName}`, className: styles$c.remove, onClick: () => onRemovePassenger?.(passenger), children: jsx(TrashIcon$2, { size: 16 }) }) })] }, passenger.id)))] })] }) })] })) : (jsxs("section", { children: [!locked && jsxs("div", { className: styles$c.tableActions, children: [jsxs("strong", { children: [equipment.length, " Equipment Items"] }), jsx(Button, { size: "sm", leftIcon: jsx(PlusIcon$2, { size: 15 }), onClick: onAddEquipment, children: "Add Equipment" })] }), jsx("div", { className: styles$c.tableWrap, children: jsxs("table", { children: [jsx("thead", { children: jsxs("tr", { children: [jsx("th", { children: "Equipment" }), jsx("th", { children: "Quantity" }), jsx("th", { children: "Weight" }), jsx("th", { children: "Total" }), jsx("th", {})] }) }), jsx("tbody", { children: equipment.map((item) => jsxs("tr", { children: [jsx("td", { children: jsx("strong", { children: item.name }) }), jsx("td", { children: item.quantity }), jsxs("td", { children: [item.weight.toLocaleString(), " lb"] }), jsxs("td", { children: [(item.quantity * item.weight).toLocaleString(), " lb"] }), jsx("td", { children: !locked && jsx("button", { type: "button", "aria-label": `Remove ${item.name}`, className: styles$c.remove, onClick: () => onRemoveEquipment?.(item), children: jsx(TrashIcon$2, { size: 16 }) }) })] }, item.id)) })] }) })] })), !locked && (jsxs("section", { className: styles$c.finalize, children: [jsx(StatusPill, { sendState: sendState, locked: false }), jsx("p", { children: sendState === 'initial-sent' ? 'Initial manifest sent. The final manifest may be sent within 3 days of departure.' : 'No manifest has been transmitted to the carrier yet.' }), jsxs("div", { className: styles$c.finalizeActions, children: [sendState === 'none' && jsx(Button, { onClick: onSendInitial, children: "Send Initial Manifest" }), sendState === 'initial-sent' && jsxs(Fragment, { children: [jsx(Button, { onClick: onSendFinal, children: "Send Final Manifest" }), jsx(Button, { variant: "ghost", size: "sm", onClick: onUndoInitial, children: "Undo initial" })] })] })] }))] })] })] }));
|
|
2524
2529
|
};
|
|
2525
2530
|
|
|
2526
|
-
var styles$
|
|
2531
|
+
var styles$b = {"page":"ContactUsPage-module_page__j9LWO","container":"ContactUsPage-module_container__uRC-r","header":"ContactUsPage-module_header__I6ypu","printRow":"ContactUsPage-module_printRow__d7O34","primaryGrid":"ContactUsPage-module_primaryGrid__DwUt4","genericGrid":"ContactUsPage-module_genericGrid__Zn-A1","stack":"ContactUsPage-module_stack__uKL2n","card":"ContactUsPage-module_card__WPn4v","cardBody":"ContactUsPage-module_cardBody__FU1io","simpleContact":"ContactUsPage-module_simpleContact__E-jyI","field":"ContactUsPage-module_field__yiMo-","label":"ContactUsPage-module_label__C2fa2","emergencyLabel":"ContactUsPage-module_emergencyLabel__Twetf","emergencyDot":"ContactUsPage-module_emergencyDot__Yg4eF","fieldValue":"ContactUsPage-module_fieldValue__5VT5g","contactColumn":"ContactUsPage-module_contactColumn__U9DGB","support":"ContactUsPage-module_support__Pptkm","emergency":"ContactUsPage-module_emergency__ozZbU","contactPair":"ContactUsPage-module_contactPair__Fxg8p","motorcoachEmergency":"ContactUsPage-module_motorcoachEmergency__-Uo84","centeredState":"ContactUsPage-module_centeredState__eLf0U","error":"ContactUsPage-module_error__XXiUk","warning":"ContactUsPage-module_warning__1--Zg"};
|
|
2527
2532
|
|
|
2528
2533
|
const cleanEmail = (email) => email?.replace('.invalid', '');
|
|
2529
|
-
const ContactField = ({ label, children, emergency = false }) => (jsxs("div", { className: styles$
|
|
2530
|
-
const ContactCard = ({ title, children }) => (jsxs("section", { className: styles$
|
|
2534
|
+
const ContactField = ({ label, children, emergency = false }) => (jsxs("div", { className: styles$b.field, children: [jsxs("span", { className: emergency ? styles$b.emergencyLabel : styles$b.label, children: [label, emergency && jsx("span", { className: styles$b.emergencyDot })] }), jsx("div", { className: styles$b.fieldValue, children: children })] }));
|
|
2535
|
+
const ContactCard = ({ title, children }) => (jsxs("section", { className: styles$b.card, children: [jsx("h2", { children: title }), jsx("div", { className: styles$b.cardBody, children: children })] }));
|
|
2531
2536
|
const SimpleContactCard = ({ title, contacts = [] }) => {
|
|
2532
2537
|
const validContacts = contacts.filter((contact) => contact.name || contact.email || contact.phone);
|
|
2533
2538
|
if (!validContacts.length)
|
|
2534
2539
|
return null;
|
|
2535
|
-
return (jsx(ContactCard, { title: title, children: validContacts.map((contact, index) => (jsxs("div", { className: styles$
|
|
2540
|
+
return (jsx(ContactCard, { title: title, children: validContacts.map((contact, index) => (jsxs("div", { className: styles$b.simpleContact, children: [contact.name && jsx(ContactField, { label: "Name:", children: jsx("span", { children: contact.name }) }), contact.email && jsx(ContactField, { label: "Email:", children: jsx("a", { href: `mailto:${cleanEmail(contact.email)}`, children: cleanEmail(contact.email) }) }), contact.phone && jsx(ContactField, { label: "Phone:", children: jsx("span", { children: contact.phone }) })] }, `${contact.email ?? contact.name ?? contact.phone}-${index}`))) }));
|
|
2536
2541
|
};
|
|
2537
|
-
const ContactColumn = ({ title, contact }) => (jsxs("div", { className: styles$
|
|
2538
|
-
const PairedContacts = ({ contacts = [] }) => (jsx(Fragment, { children: contacts.map((contact, index) => (jsxs("div", { className: styles$
|
|
2539
|
-
const GenericCards = ({ cards }) => (jsx("div", { className: styles$
|
|
2542
|
+
const ContactColumn = ({ title, contact }) => (jsxs("div", { className: styles$b.contactColumn, children: [jsx("strong", { children: title }), contact?.name && jsx("span", { children: contact.name }), contact?.email && jsx("a", { href: `mailto:${cleanEmail(contact.email)}`, children: cleanEmail(contact.email) }), contact?.phone && jsxs("span", { children: [contact.phone, contact.show247 && jsx("em", { children: " (24/7)" })] })] }));
|
|
2543
|
+
const PairedContacts = ({ contacts = [] }) => (jsx(Fragment, { children: contacts.map((contact, index) => (jsxs("div", { className: styles$b.contactPair, children: [jsx(ContactColumn, { title: "Sales Contact", contact: contact.sales }), jsx(ContactColumn, { title: "Operations Contact", contact: contact.operations })] }, `${contact.sales?.email ?? contact.operations?.email}-${index}`))) }));
|
|
2544
|
+
const GenericCards = ({ cards }) => (jsx("div", { className: styles$b.genericGrid, children: cards.map((card) => jsx(SimpleContactCard, { title: card.title, contacts: card.contacts }, card.title)) }));
|
|
2540
2545
|
/** Exact presentational counterpart of the Hub Contact Us screen. */
|
|
2541
2546
|
const ContactUsPage = ({ title = 'Your Team of Experts', state, errorMessage = 'Unable to fetch contact information.', data, onPrint, cards = [], children, className = '', }) => {
|
|
2542
2547
|
const resolvedState = state ?? (data || cards.length || children ? 'data' : 'empty');
|
|
2543
2548
|
if (resolvedState === 'loading')
|
|
2544
2549
|
return null;
|
|
2545
2550
|
if (resolvedState === 'error' || resolvedState === 'empty') {
|
|
2546
|
-
return (jsx("div", { className: styles$
|
|
2551
|
+
return (jsx("div", { className: styles$b.centeredState, "data-test": "contact-us-page", children: jsx("div", { "data-test": `contact-us-${resolvedState}`, role: resolvedState === 'error' ? 'alert' : 'status', className: resolvedState === 'error' ? styles$b.error : styles$b.warning, children: resolvedState === 'error' ? errorMessage : 'No contact information available.' }) }));
|
|
2547
2552
|
}
|
|
2548
|
-
return (jsx("div", { className: [styles$
|
|
2553
|
+
return (jsx("div", { className: [styles$b.page, className].filter(Boolean).join(' '), "data-test": "contact-us-page", children: jsxs("div", { className: styles$b.container, children: [jsx("header", { className: styles$b.header, children: jsx("h1", { children: title }) }), jsx("div", { className: styles$b.printRow, children: jsxs("button", { type: "button", onClick: onPrint ?? (() => window.print()), children: [jsx(PrinterIcon, { size: 16 }), "Print"] }) }), children ?? (data ? (jsxs(Fragment, { children: [!!(data.accountManagers?.length || data.travelAgents?.length) && (jsxs("div", { className: styles$b.primaryGrid, children: [jsx(SimpleContactCard, { title: "Account Manager", contacts: data.accountManagers }), jsx(SimpleContactCard, { title: "Travel Agent", contacts: data.travelAgents })] })), jsxs("div", { className: styles$b.stack, children: [jsxs(ContactCard, { title: "Group/Team Commercial Reservation Specialists", children: [jsx(ContactField, { label: "Business Hours:", children: jsx("span", { children: "Monday \u2013 Friday 8am-8pm ET" }) }), jsx(ContactField, { label: "Toll-Free Number:", children: jsx("span", { children: "866-902-9654" }) }), jsx(ContactField, { label: "After Hours/Emergency (24/7):", emergency: true, children: jsx("span", { className: styles$b.emergency, children: "866-902-9654" }) }), jsx(ContactField, { label: "Email:", children: jsx("a", { href: "mailto:teamtravel@shortstravel.com", children: "teamtravel@shortstravel.com" }) })] }), jsxs(ContactCard, { title: "Recruiting Travel Specialists", children: [jsx(ContactField, { label: "Business Hours:", children: jsx("span", { children: "Monday \u2013 Friday 8am-8pm ET" }) }), jsx(ContactField, { label: "Toll-Free Number:", children: jsx("span", { children: "866-902-9654" }) }), jsx(ContactField, { label: "After Hours/Emergency (24/7):", emergency: true, children: jsx("span", { className: styles$b.emergency, children: "866-902-9654" }) }), jsx(ContactField, { label: "Email:", children: jsx("a", { href: "mailto:recruiting@shortstravel.com", children: "recruiting@shortstravel.com" }) })] }), !!data.charterAirContacts?.length && jsx(ContactCard, { title: "Charter Air", children: jsx(PairedContacts, { contacts: data.charterAirContacts }) }), !!data.motorcoachContacts?.length && (jsxs(ContactCard, { title: "Charter Bus / Motorcoach", children: [jsx(PairedContacts, { contacts: data.motorcoachContacts }), jsx("p", { className: styles$b.motorcoachEmergency, children: "After Hours/Emergency (24/7): 319-423-3007" })] })), !!data.groupHotelContacts?.length && (jsx(ContactCard, { title: "Group Hotel", children: data.groupHotelContacts.map((contact, index) => (jsxs("div", { className: styles$b.contactPair, children: [jsx(ContactColumn, { title: "Sales Contact", contact: contact }), jsx("div", { className: styles$b.contactColumn })] }, `${contact.email ?? contact.name}-${index}`))) }))] })] })) : jsx(GenericCards, { cards: cards })), jsxs("footer", { className: styles$b.support, children: [jsx("h2", { children: "Short's Travel Website and Online Booking Tool Support" }), jsx("p", { children: "Monday \u2013 Friday 9am-9pm ET, except major holidays" }), jsxs("div", { children: [jsx("span", { children: "319-257-5309" }), jsx("a", { href: "mailto:onlinesupport@shortstravel.com", children: "onlinesupport@shortstravel.com" })] })] })] }) }));
|
|
2549
2554
|
};
|
|
2550
2555
|
|
|
2551
|
-
var styles$
|
|
2556
|
+
var styles$a = {"page":"DashboardPage-module_page__PPkbS","pageHeader":"DashboardPage-module_pageHeader__gb8MO","pageActions":"DashboardPage-module_pageActions__1Zgv1","outlineButton":"DashboardPage-module_outlineButton__iLuAv","textButton":"DashboardPage-module_textButton__rEtbe","primaryButton":"DashboardPage-module_primaryButton__uaCW9","customizeButton":"DashboardPage-module_customizeButton__D6kV3","editBanner":"DashboardPage-module_editBanner__7IN5D","syncStatus":"DashboardPage-module_syncStatus__BxFQW","syncError":"DashboardPage-module_syncError__U-uis","grid":"DashboardPage-module_grid__OVgfA","sizeS":"DashboardPage-module_sizeS__leLYa","sizeM":"DashboardPage-module_sizeM__TkfbJ","sizeL":"DashboardPage-module_sizeL__Gbs5b","widget":"DashboardPage-module_widget__p6N-1","editing":"DashboardPage-module_editing__rtEwa","widgetHeader":"DashboardPage-module_widgetHeader__m7YWn","widgetIcon":"DashboardPage-module_widgetIcon__1npXI","dragHandle":"DashboardPage-module_dragHandle__rWGWh","rangeTitle":"DashboardPage-module_rangeTitle__IxHJR","widgetActions":"DashboardPage-module_widgetActions__E2pfv","iconButton":"DashboardPage-module_iconButton__v7jtL","sizeToggle":"DashboardPage-module_sizeToggle__wmv6Y","activeSize":"DashboardPage-module_activeSize__vFi0w","widgetBody":"DashboardPage-module_widgetBody__8IPCC","skeleton":"DashboardPage-module_skeleton__V--PR","pulse":"DashboardPage-module_pulse__VLsO0","state":"DashboardPage-module_state__h3q31","tableBody":"DashboardPage-module_tableBody__iJCJd","tableRow":"DashboardPage-module_tableRow__N5FgV","travelersGrid":"DashboardPage-module_travelersGrid__bYR9i","unusedGrid":"DashboardPage-module_unusedGrid__WyJzI","tableHead":"DashboardPage-module_tableHead__n3RLy","typeChips":"DashboardPage-module_typeChips__zCQA2","carrier":"DashboardPage-module_carrier__EAgok","nearExpiry":"DashboardPage-module_nearExpiry__u13P9","summary":"DashboardPage-module_summary__5kp8D","infoList":"DashboardPage-module_infoList__seS0s","rows":"DashboardPage-module_rows__rPy8n","row":"DashboardPage-module_row__uIAgO","widgetFooter":"DashboardPage-module_widgetFooter__OWOyX","editFooter":"DashboardPage-module_editFooter__OHwct","emptyPage":"DashboardPage-module_emptyPage__2QBJk","scrim":"DashboardPage-module_scrim__9ftDX","catalog":"DashboardPage-module_catalog__PoSpA","catalogBody":"DashboardPage-module_catalogBody__AmzLB","catalogItem":"DashboardPage-module_catalogItem__tgxzn","catalogIcon":"DashboardPage-module_catalogIcon__rXPbn","added":"DashboardPage-module_added__c9XNj","dragGhost":"DashboardPage-module_dragGhost__OemVj"};
|
|
2552
2557
|
|
|
2553
2558
|
const CATALOG = [
|
|
2554
2559
|
{ type: 'travelers', title: "Today's Travelers", description: 'Current travelers with dates and travel types, plus the Where Are My Travelers report.' },
|
|
@@ -2564,12 +2569,12 @@ const TRAVELER_RANGES = [
|
|
|
2564
2569
|
];
|
|
2565
2570
|
const rowsForSize = (size) => size === 'S' ? 3 : size === 'M' ? 6 : 10;
|
|
2566
2571
|
const WidgetIcon = ({ type }) => type === 'travelers' ? jsx(UserIcon, { size: 20 }) : jsx(InfoIcon$1, { size: 20 });
|
|
2567
|
-
const LoadingState = () => jsxs("div", { className: styles$
|
|
2568
|
-
const EmptyState = ({ message }) => jsxs("div", { className: styles$
|
|
2569
|
-
const ErrorState = ({ onRetry }) => jsxs("div", { className: styles$
|
|
2570
|
-
const TravelersBody = ({ records, size }) => (jsxs("div", { className: styles$
|
|
2571
|
-
const UnusedBody = ({ records, size, totalAmount = '$0.00' }) => (jsxs("div", { className: styles$
|
|
2572
|
-
const InfoBody = ({ records, size, onNavigate }) => (jsx("div", { className: styles$
|
|
2572
|
+
const LoadingState = () => jsxs("div", { className: styles$a.skeleton, children: [jsx("i", {}), jsx("i", {}), jsx("i", {}), jsx("span", { children: "Refreshing\u2026" })] });
|
|
2573
|
+
const EmptyState = ({ message }) => jsxs("div", { className: styles$a.state, children: [jsx(CheckIcon$2, { size: 28 }), jsx("span", { children: message })] });
|
|
2574
|
+
const ErrorState = ({ onRetry }) => jsxs("div", { className: styles$a.state, children: [jsx(WarningIcon$1, { size: 28 }), jsx("span", { children: "Couldn't load this card." }), jsxs("button", { type: "button", onClick: onRetry, children: [jsx(RefreshIcon, { size: 16 }), "Retry"] })] });
|
|
2575
|
+
const TravelersBody = ({ records, size }) => (jsxs("div", { className: styles$a.tableBody, children: [jsxs("div", { className: [styles$a.tableRow, styles$a.travelersGrid, styles$a.tableHead].join(' '), children: [jsx("span", { children: "Traveler(s)" }), jsx("span", { children: "Dates" }), jsx("span", { children: "Types" })] }), records.slice(0, rowsForSize(size)).map((record, index, visible) => (jsxs("div", { className: [styles$a.tableRow, styles$a.travelersGrid].join(' '), "data-last": index === visible.length - 1, children: [jsx("strong", { children: record.traveler }), jsx("span", { children: record.dates }), jsx("span", { className: styles$a.typeChips, children: record.types.map((type) => jsx("b", { title: type, children: type }, type)) })] }, `${record.traveler}-${index}`)))] }));
|
|
2576
|
+
const UnusedBody = ({ records, size, totalAmount = '$0.00' }) => (jsxs("div", { className: styles$a.tableBody, children: [jsxs("div", { className: [styles$a.tableRow, styles$a.unusedGrid, styles$a.tableHead].join(' '), children: [jsx("span", { children: "Traveler" }), jsx("span", { children: "Air" }), jsx("span", { children: "Exp" }), jsx("span", { children: "Amount" })] }), records.slice(0, rowsForSize(size)).map((record, index, visible) => (jsxs("div", { className: [styles$a.tableRow, styles$a.unusedGrid].join(' '), "data-last": index === visible.length - 1, children: [jsx("span", { children: record.traveler }), jsxs("strong", { className: styles$a.carrier, children: [record.airlineLogo && jsx("img", { src: record.airlineLogo, alt: "" }), record.airline] }), jsx("span", { className: record.expDays <= 28 ? styles$a.nearExpiry : '', children: record.exp }), jsx("strong", { children: record.amount })] }, `${record.traveler}-${index}`))), jsxs("div", { className: styles$a.summary, children: [jsxs("span", { children: [records.length, " unused ticket", records.length === 1 ? '' : 's'] }), jsxs("span", { children: ["Total ", jsx("strong", { children: totalAmount })] })] })] }));
|
|
2577
|
+
const InfoBody = ({ records, size, onNavigate }) => (jsx("div", { className: styles$a.infoList, children: records.slice(0, size === 'S' ? 3 : size === 'M' ? 5 : 9).map((item) => item.href ? (jsxs("a", { href: item.href, target: "_blank", rel: "noopener noreferrer", children: [jsxs("span", { children: [jsx("strong", { children: item.title }), item.body && jsx("small", { children: item.body })] }), jsx("b", { children: "\u2197" })] }, item.id)) : (jsxs("button", { type: "button", onClick: () => onNavigate?.('/info-center', { openArticleId: item.id }), children: [jsxs("span", { children: [jsx("strong", { children: item.title }), item.body && jsx("small", { children: item.body })] }), jsx("b", { children: "\u203A" })] }, item.id))) }));
|
|
2573
2578
|
const WidgetBody = ({ widget, onNavigate }) => {
|
|
2574
2579
|
if (widget.travelerRecords)
|
|
2575
2580
|
return jsx(TravelersBody, { records: widget.travelerRecords, size: widget.size });
|
|
@@ -2577,7 +2582,7 @@ const WidgetBody = ({ widget, onNavigate }) => {
|
|
|
2577
2582
|
return jsx(UnusedBody, { records: widget.unusedRecords, totalAmount: widget.unusedTotalAmount, size: widget.size });
|
|
2578
2583
|
if (widget.infoCenterRecords)
|
|
2579
2584
|
return jsx(InfoBody, { records: widget.infoCenterRecords, size: widget.size, onNavigate: onNavigate });
|
|
2580
|
-
return jsx("div", { className: styles$
|
|
2585
|
+
return jsx("div", { className: styles$a.rows, children: widget.rows?.map((row, index) => jsxs("div", { className: styles$a.row, children: [jsxs("div", { children: [jsx("strong", { children: row.primary }), row.secondary && jsx("span", { children: row.secondary })] }), row.badge && jsx("small", { children: row.badge }), row.value && jsx("b", { children: row.value })] }, `${row.primary}-${index}`)) });
|
|
2581
2586
|
};
|
|
2582
2587
|
const WidgetCard = ({ widget, editMode, index, count, onRefresh, onRemove, onResize, onReorder, onTravelerRangeChange, onNavigate }) => {
|
|
2583
2588
|
const [rangeIndex, setRangeIndex] = useState(2);
|
|
@@ -2588,7 +2593,7 @@ const WidgetCard = ({ widget, editMode, index, count, onRefresh, onRemove, onRes
|
|
|
2588
2593
|
onTravelerRangeChange?.(widget, TRAVELER_RANGES[next].key);
|
|
2589
2594
|
};
|
|
2590
2595
|
const state = widget.state ?? 'data';
|
|
2591
|
-
return (jsxs("article", { className: [styles$
|
|
2596
|
+
return (jsxs("article", { className: [styles$a.widget, editMode ? styles$a.editing : ''].filter(Boolean).join(' '), children: [jsxs("header", { className: styles$a.widgetHeader, children: [editMode && jsx("span", { className: styles$a.dragHandle, "aria-hidden": "true", children: "\u283F" }), jsx("span", { className: styles$a.widgetIcon, children: jsx(WidgetIcon, { type: widget.type }) }), isTravelers ? jsxs("div", { className: styles$a.rangeTitle, children: [jsx("button", { type: "button", "aria-label": "Show previous traveler range", disabled: rangeIndex === 0, onClick: () => changeRange(-1), children: jsx(ChevronLeftIcon, { size: 14 }) }), jsx("h3", { children: TRAVELER_RANGES[rangeIndex].label }), jsx("button", { type: "button", "aria-label": "Show next traveler range", disabled: rangeIndex === TRAVELER_RANGES.length - 1, onClick: () => changeRange(1), children: jsx(ChevronRightIcon$1, { size: 14 }) })] }) : jsx("h3", { children: widget.title }), jsx("div", { className: styles$a.widgetActions, children: editMode ? jsxs(Fragment, { children: [jsx("span", { className: styles$a.sizeToggle, role: "group", "aria-label": `${widget.title} size`, children: ['S', 'M', 'L'].map((size) => jsx("button", { type: "button", "aria-label": { S: 'Small', M: 'Medium', L: 'Large' }[size], "aria-pressed": widget.size === size, className: widget.size === size ? styles$a.activeSize : '', onClick: () => onResize?.(widget, size), children: size }, size)) }), !widget.pinned && jsx("button", { type: "button", className: styles$a.iconButton, "aria-label": `Remove ${widget.title} card`, onClick: () => onRemove?.(widget), children: jsx(CloseIcon, { size: 16 }) })] }) : jsx("button", { type: "button", className: styles$a.iconButton, "aria-label": `Refresh ${widget.title}`, onClick: () => onRefresh?.(widget), disabled: state === 'loading', children: jsx(RefreshIcon, { size: 20 }) }) })] }), jsx("div", { className: styles$a.widgetBody, children: state === 'loading' ? jsx(LoadingState, {}) : state === 'error' ? jsx(ErrorState, { onRetry: () => onRefresh?.(widget) }) : state === 'empty' ? jsx(EmptyState, { message: widget.emptyMessage ?? 'No records available.' }) : jsx(WidgetBody, { widget: widget, onNavigate: onNavigate }) }), !editMode && (state === 'data' || state === 'empty') && (widget.footerLabel || widget.footerSecondary) && jsxs("footer", { className: styles$a.widgetFooter, children: [widget.footerSecondary && state === 'data' && jsxs("button", { type: "button", onClick: () => onNavigate?.(widget.footerSecondary.path), children: [jsx(FilterIcon$1, { size: 16 }), widget.footerSecondary.label] }), widget.footerLabel && jsxs("button", { type: "button", onClick: () => onNavigate?.(widget.footerPath ?? '#'), children: [widget.footerLabel, jsx("span", { children: "\u2192" })] })] }), editMode && jsxs("footer", { className: styles$a.editFooter, children: [jsx("span", { children: "Reorder" }), jsx("button", { type: "button", "aria-label": `Move ${widget.title} earlier`, disabled: index === 0, onClick: () => onReorder?.(index, index - 1), children: "\u2190" }), jsx("button", { type: "button", "aria-label": `Move ${widget.title} later`, disabled: index === count - 1, onClick: () => onReorder?.(index, index + 1), children: "\u2192" })] })] }));
|
|
2592
2597
|
};
|
|
2593
2598
|
/** Exact, service-free rendering of Hub's personalized home page. */
|
|
2594
2599
|
const DashboardPage = ({ greeting = 'Good morning', firstName, accountName, widgets = [], systemBanners = [], alertBanners = [], syncStatus = 'idle', onRefresh, onRemove, onResize, onReorder, onReset, onAddWidget, onTravelerRangeChange, onNavigate, className = '' }) => {
|
|
@@ -2597,12 +2602,12 @@ const DashboardPage = ({ greeting = 'Good morning', firstName, accountName, widg
|
|
|
2597
2602
|
const [dragFrom, setDragFrom] = useState(null);
|
|
2598
2603
|
const dragGhost = useRef(null);
|
|
2599
2604
|
const presentTypes = new Set(widgets.map((widget) => widget.type));
|
|
2600
|
-
return (jsxs("div", { className: [styles$
|
|
2601
|
-
return; setDragFrom(index); const ghost = document.createElement('div'); ghost.className = styles$
|
|
2602
|
-
onReorder?.(dragFrom, index); setDragFrom(null); }, onDragEnd: () => { setDragFrom(null); dragGhost.current?.remove(); dragGhost.current = null; }, children: jsx(WidgetCard, { widget: widget, editMode: editMode, index: index, count: widgets.length, onRefresh: onRefresh, onRemove: onRemove, onResize: onResize, onReorder: onReorder, onTravelerRangeChange: onTravelerRangeChange, onNavigate: onNavigate }) }, widget.id)) }) : jsxs("div", { className: styles$
|
|
2605
|
+
return (jsxs("div", { className: [styles$a.page, className].filter(Boolean).join(' '), children: [jsx(PageBanners, { systemBanners: systemBanners, alertBanners: alertBanners }), jsxs("header", { className: styles$a.pageHeader, children: [jsxs("div", { children: [jsxs("h1", { children: [greeting, firstName ? `, ${firstName}` : ''] }), accountName && jsxs("p", { children: ["Here's your personalized travel overview for ", accountName, "."] })] }), jsx("div", { className: styles$a.pageActions, children: editMode ? jsxs(Fragment, { children: [jsxs("button", { type: "button", className: styles$a.outlineButton, onClick: () => setCatalogOpen(true), children: [jsx(PlusIcon$2, { size: 20 }), "Add card"] }), jsx("button", { type: "button", className: styles$a.textButton, onClick: onReset, children: "Reset to default" }), jsxs("button", { type: "button", className: styles$a.primaryButton, onClick: () => { setEditMode(false); setCatalogOpen(false); }, children: [jsx(CheckIcon$2, { size: 20 }), "Done"] })] }) : jsxs("button", { type: "button", className: styles$a.customizeButton, onClick: () => setEditMode(true), children: [jsx(SettingsIcon, { size: 20 }), "Customize Your Home Page"] }) })] }), editMode && jsxs("div", { className: styles$a.editBanner, children: [jsx(EditIcon$2, { size: 20 }), jsxs("span", { children: [jsx("strong", { children: "Customizing your home page." }), " Drag cards to reorder, resize with S / M / L, or remove cards. Your layout saves automatically."] })] }), syncStatus === 'saving' && jsx("p", { className: styles$a.syncStatus, "aria-live": "polite", children: "Saving layout\u2026" }), syncStatus === 'error' && jsx("p", { className: [styles$a.syncStatus, styles$a.syncError].join(' '), role: "alert", children: "Layout couldn't be saved. Changes are preserved locally." }), widgets.length ? jsx("div", { className: styles$a.grid, children: widgets.map((widget, index) => jsx("div", { className: styles$a[`size${widget.size}`], draggable: editMode, onDragStart: (event) => { if (!editMode)
|
|
2606
|
+
return; setDragFrom(index); const ghost = document.createElement('div'); ghost.className = styles$a.dragGhost; document.body.appendChild(ghost); dragGhost.current = ghost; event.dataTransfer.setDragImage(ghost, 0, 0); }, onDragOver: (event) => event.preventDefault(), onDrop: () => { if (dragFrom !== null && dragFrom !== index)
|
|
2607
|
+
onReorder?.(dragFrom, index); setDragFrom(null); }, onDragEnd: () => { setDragFrom(null); dragGhost.current?.remove(); dragGhost.current = null; }, children: jsx(WidgetCard, { widget: widget, editMode: editMode, index: index, count: widgets.length, onRefresh: onRefresh, onRemove: onRemove, onResize: onResize, onReorder: onReorder, onTravelerRangeChange: onTravelerRangeChange, onNavigate: onNavigate }) }, widget.id)) }) : jsxs("div", { className: styles$a.emptyPage, children: [jsx(PlusIcon$2, { size: 28 }), jsx("strong", { children: "Your home page is empty" }), jsx("span", { children: "Use \"Customize\" to add cards from the catalog." })] }), catalogOpen && jsxs(Fragment, { children: [jsx("button", { type: "button", className: styles$a.scrim, "aria-label": "Close card catalog", onClick: () => setCatalogOpen(false) }), jsxs("aside", { className: styles$a.catalog, role: "dialog", "aria-modal": "true", "aria-label": "Add cards", children: [jsxs("header", { children: [jsxs("div", { children: [jsx("h2", { children: "Add a card" }), jsx("p", { children: "Cards available to your role for this account" })] }), jsx("button", { type: "button", "aria-label": "Close card catalog", onClick: () => setCatalogOpen(false), children: jsx(CloseIcon, { size: 20 }) })] }), jsx("div", { className: styles$a.catalogBody, children: CATALOG.map((item) => jsxs("div", { className: styles$a.catalogItem, children: [jsx("span", { className: styles$a.catalogIcon, children: jsx(WidgetIcon, { type: item.type }) }), jsxs("div", { children: [jsx("strong", { children: item.title }), jsx("span", { children: "Account" }), jsx("p", { children: item.description })] }), presentTypes.has(item.type) ? jsxs("span", { className: styles$a.added, children: [jsx(CheckIcon$2, { size: 16 }), "Added"] }) : jsxs("button", { type: "button", onClick: () => onAddWidget?.(item.type), children: [jsx(PlusIcon$2, { size: 16 }), "Add"] })] }, item.type)) }), jsx("footer", { children: "Each card can appear once on your home page." })] })] })] }));
|
|
2603
2608
|
};
|
|
2604
2609
|
|
|
2605
|
-
var styles$
|
|
2610
|
+
var styles$9 = {"page":"GroupTravelRequestPage-module_page__0JriY","pageHeader":"GroupTravelRequestPage-module_pageHeader__oP6rE","workspace":"GroupTravelRequestPage-module_workspace__SIOli","serviceSidebar":"GroupTravelRequestPage-module_serviceSidebar__XUlqR","tripEvents":"GroupTravelRequestPage-module_tripEvents__6Upvv","formMain":"GroupTravelRequestPage-module_formMain__pFK7N","serviceSection":"GroupTravelRequestPage-module_serviceSection__10nXm","summarySidebar":"GroupTravelRequestPage-module_summarySidebar__HoAGy","summaryCard":"GroupTravelRequestPage-module_summaryCard__YvX-g","summarySection":"GroupTravelRequestPage-module_summarySection__uY5FU","summaryRow":"GroupTravelRequestPage-module_summaryRow__el7jN","emptySummary":"GroupTravelRequestPage-module_emptySummary__veL9N","field":"GroupTravelRequestPage-module_field__-HfoK","label":"GroupTravelRequestPage-module_label__sEOeK","input":"GroupTravelRequestPage-module_input__lXQDl","select":"GroupTravelRequestPage-module_select__D7ICw","textarea":"GroupTravelRequestPage-module_textarea__AYtX1","note":"GroupTravelRequestPage-module_note__9loDq","choiceFieldset":"GroupTravelRequestPage-module_choiceFieldset__dMlZv","radioGroup":"GroupTravelRequestPage-module_radioGroup__xP97-","radioLabel":"GroupTravelRequestPage-module_radioLabel__9wYXU","checkToggle":"GroupTravelRequestPage-module_checkToggle__PZAHF","segments":"GroupTravelRequestPage-module_segments__07a9Y","contactGroup":"GroupTravelRequestPage-module_contactGroup__MQ7mD","destinationList":"GroupTravelRequestPage-module_destinationList__uaHzR","segmentHeader":"GroupTravelRequestPage-module_segmentHeader__8a1Re","destinationRow":"GroupTravelRequestPage-module_destinationRow__swSrv","pageFooter":"GroupTravelRequestPage-module_pageFooter__mQcPZ","pageButtons":"GroupTravelRequestPage-module_pageButtons__jfH5X","currentPage":"GroupTravelRequestPage-module_currentPage__WfmWO","mobileTabs":"GroupTravelRequestPage-module_mobileTabs__GEAo2","mobileServices":"GroupTravelRequestPage-module_mobileServices__XN2Vw","mobileEnable":"GroupTravelRequestPage-module_mobileEnable__DRf4H","activeTab":"GroupTravelRequestPage-module_activeTab__dolkN","activeService":"GroupTravelRequestPage-module_activeService__VXHEF","mobileHidden":"GroupTravelRequestPage-module_mobileHidden__RYc4x","summaryMobileHidden":"GroupTravelRequestPage-module_summaryMobileHidden__0QaCt"};
|
|
2606
2611
|
|
|
2607
2612
|
const FLIGHT_TYPES = ['One Way', 'Round Trip', 'Multiple Destinations'];
|
|
2608
2613
|
const FLIGHT_TIMES = [
|
|
@@ -2646,12 +2651,12 @@ const Field = ({ label, name, values, setValue, type = 'text', required, disable
|
|
|
2646
2651
|
'aria-describedby': note ? `${inputId}-note` : undefined,
|
|
2647
2652
|
onChange: (event) => setValue(name, event.target.value),
|
|
2648
2653
|
};
|
|
2649
|
-
return (jsxs("div", { className: styles$
|
|
2654
|
+
return (jsxs("div", { className: styles$9.field, children: [jsxs("label", { className: styles$9.label, htmlFor: inputId, children: [label, required && jsx("span", { "aria-hidden": "true", children: " *" })] }), multiline ? (jsx("textarea", { ...common, className: styles$9.textarea, rows: 3, maxLength: 5000, placeholder: placeholder })) : options ? (jsxs("select", { ...common, className: styles$9.select, children: [jsx("option", { value: "", children: "Select" }), options.map((option) => jsx("option", { value: option.value, children: option.label }, option.value))] })) : (jsx("input", { ...common, className: styles$9.input, type: type, max: type === 'date' ? maxDate : max, min: type === 'date' ? textValue(min) : min, placeholder: placeholder })), note && jsx("div", { className: styles$9.note, id: `${inputId}-note`, children: note })] }));
|
|
2650
2655
|
};
|
|
2651
|
-
const ChoiceGroup = ({ label, name, options, values, setValue, required, }) => (jsxs("fieldset", { className: styles$
|
|
2652
|
-
const CheckToggle = ({ label, name, values, setValue, }) => (jsxs("div", { className: styles$
|
|
2656
|
+
const ChoiceGroup = ({ label, name, options, values, setValue, required, }) => (jsxs("fieldset", { className: styles$9.choiceFieldset, children: [jsxs("legend", { className: styles$9.label, children: [label, required && jsx("span", { "aria-hidden": "true", children: " *" })] }), jsx("div", { className: styles$9.radioGroup, children: options.map((option) => (jsxs("label", { className: styles$9.radioLabel, children: [jsx("input", { type: "radio", name: name, value: option, checked: values[name] === option, onChange: () => setValue(name, option), required: required }), jsx("span", { children: option })] }, option))) })] }));
|
|
2657
|
+
const CheckToggle = ({ label, name, values, setValue, }) => (jsxs("div", { className: styles$9.checkToggle, children: [jsx(Toggle, { "aria-label": label, checked: isEnabledValue(values[name]), onChange: (checked) => setValue(name, checked ? 1 : 0), size: "sm" }), jsx("span", { children: label })] }));
|
|
2653
2658
|
const YesNo = ({ label, name, values, setValue }) => (jsx(ChoiceGroup, { label: label, name: name, options: ['Yes', 'No'], values: { ...values, [name]: values[name] === 1 ? 'Yes' : values[name] === 0 ? 'No' : values[name] }, setValue: (_, value) => setValue(name, value === 'Yes' ? 1 : 0), required: true }));
|
|
2654
|
-
const SegmentHeader = ({ label, index, canDelete, onDelete }) => (jsxs("div", { className: styles$
|
|
2659
|
+
const SegmentHeader = ({ label, index, canDelete, onDelete }) => (jsxs("div", { className: styles$9.segmentHeader, children: [jsxs("span", { children: [label, " ", index + 1] }), canDelete && jsxs(Button, { type: "button", size: "sm", variant: "outline", rightIcon: jsx(TrashIcon$2, { size: 14 }), onClick: onDelete, children: ["Delete ", label] })] }));
|
|
2655
2660
|
const FlightRequest = ({ prefix, values, setValue, cateringOptions, }) => {
|
|
2656
2661
|
const typeName = `${prefix}multiplesegments`;
|
|
2657
2662
|
const flightType = textValue(values[typeName]);
|
|
@@ -2676,7 +2681,7 @@ const FlightRequest = ({ prefix, values, setValue, cateringOptions, }) => {
|
|
|
2676
2681
|
setValue(name, value);
|
|
2677
2682
|
if (value === 'Round Trip')
|
|
2678
2683
|
setCount(1);
|
|
2679
|
-
}, required: true }), jsxs("div", { className: styles$
|
|
2684
|
+
}, required: true }), jsxs("div", { className: styles$9.segments, children: [Array.from({ length: count }, (_, index) => {
|
|
2680
2685
|
const departLocation = fieldName('departlocation', index);
|
|
2681
2686
|
const departDate = fieldName('departdate', index);
|
|
2682
2687
|
const departTime = fieldName('departtime', index);
|
|
@@ -2705,7 +2710,7 @@ const HotelRequest = ({ values, setValue }) => {
|
|
|
2705
2710
|
const other = type === 'kings' ? 'doubles' : 'kings';
|
|
2706
2711
|
setValue(hotelFieldName('rooms', index), Number(value || 0) + Number(values[hotelFieldName(other, index)] || 0));
|
|
2707
2712
|
};
|
|
2708
|
-
return jsxs(Fragment, { children: [totalRooms > 0 && totalRooms < 8 && jsxs(Alert, { children: [jsx("strong", { children: "NOTE:" }), " Seven or fewer rooms are booked by an agent instead of STM Stay."] }), jsxs("div", { className: styles$
|
|
2713
|
+
return jsxs(Fragment, { children: [totalRooms > 0 && totalRooms < 8 && jsxs(Alert, { children: [jsx("strong", { children: "NOTE:" }), " Seven or fewer rooms are booked by an agent instead of STM Stay."] }), jsxs("div", { className: styles$9.segments, children: [Array.from({ length: count }, (_, index) => jsxs(Accordion, { header: jsx(SegmentHeader, { label: "Hotel", index: index, canDelete: count > 1, onDelete: () => deleteHotel(index) }), showTimeline: true, children: [jsx(Field, { label: "City", name: hotelFieldName('hotellocation', index), values: values, setValue: setValue, required: true }), jsx(Field, { label: "Preferred Hotel(s)", name: hotelFieldName('hotelproperty', index), values: values, setValue: setValue }), jsxs(FormRow, { columns: 3, children: [jsx(Field, { label: "# of King Rooms", name: hotelFieldName('kings', index), values: values, setValue: (_name, value) => updateRooms(index, 'kings', value), type: "number", min: 0, max: 999, required: true }), jsx(Field, { label: "# of Double Rooms", name: hotelFieldName('doubles', index), values: values, setValue: (_name, value) => updateRooms(index, 'doubles', value), type: "number", min: 0, max: 999, required: true }), jsx(Field, { label: "Total Rooms", name: hotelFieldName('rooms', index), values: values, setValue: setValue, disabled: true })] }), jsx(Alert, { variant: "error", children: "Please include bus driver room if needed." }), jsxs(FormRow, { columns: 2, children: [jsx(Field, { label: "Check-In Date", name: hotelFieldName('checkin', index), values: values, setValue: setValue, type: "date", min: textValue(values.tripstartdate), maxDate: textValue(values.tripreturndate), required: true }), jsx(Field, { label: "Check-Out Date", name: hotelFieldName('checkout', index), values: values, setValue: setValue, type: "date", min: textValue(values[hotelFieldName('checkin', index)]) || textValue(values.tripstartdate), maxDate: textValue(values.tripreturndate), required: true })] })] }, index)), count < 3 && jsx("div", { children: jsx(Button, { type: "button", size: "sm", variant: "secondary", rightIcon: jsx(PlusIcon$2, { size: 16 }), onClick: () => setCount((current) => current + 1), children: "Add Hotel" }) })] }), jsx(YesNo, { label: "Do you need a room for the bus driver?", name: "busdriverroom", values: values, setValue: setValue }), totalRooms > 7 && jsxs(Fragment, { children: [jsx(YesNo, { label: "Do you need meeting space for the team?", name: "teammeetingspaceflag", values: values, setValue: setValue }), Number(values.teammeetingspaceflag) === 1 && jsx(Field, { label: "How many people do you need the meeting space set for?", name: "teammeetingspace", values: values, setValue: setValue, type: "number", min: 1, max: 999, required: true })] }), jsx(Field, { label: "General Notes on Hotel Request", name: "details_hotel", values: values, setValue: setValue, multiline: true })] });
|
|
2709
2714
|
};
|
|
2710
2715
|
const VehicleRentalRequest = ({ values, setValue }) => {
|
|
2711
2716
|
const hasAir = isEnabledValue(values.air) || isEnabledValue(values.charter);
|
|
@@ -2731,9 +2736,9 @@ const BusRequest = ({ values, setValue, schoolAddress }) => {
|
|
|
2731
2736
|
setValue(destinationName(position), position === destinations - 1 ? '' : values[destinationName(position + 1)]);
|
|
2732
2737
|
setDestinations((current) => Math.max(1, current - 1));
|
|
2733
2738
|
};
|
|
2734
|
-
return jsxs(Fragment, { children: [jsx(ChoiceGroup, { label: "Charter Bus Type", name: "bustype", options: BUS_TYPES, values: values, setValue: updateBusType, required: true }), busType && busType !== BUS_TYPES[0] && jsx(CheckToggle, { label: "Do you need local airport transfers?", name: "buslocalairporttransfers", values: values, setValue: setValue }), jsxs(FormRow, { columns: 3, children: [jsx(Field, { label: "Pickup Date", name: "buspickupdate", values: values, setValue: setValue, type: "date", min: textValue(values.tripstartdate), maxDate: textValue(values.tripreturndate), required: true }), jsx(Field, { label: "Pickup Time", name: "buspickuptime", values: values, setValue: setValue, type: "time", required: true }), jsx(Field, { label: "# of Buses", name: "numbuses", values: values, setValue: setValue, type: "number", min: 1, max: 99, required: true })] }), jsx(Field, { label: "Motorcoach/Airport Pickup Location", name: "buspickuplocation", values: values, setValue: setValue, required: true }), jsxs("div", { className: styles$
|
|
2739
|
+
return jsxs(Fragment, { children: [jsx(ChoiceGroup, { label: "Charter Bus Type", name: "bustype", options: BUS_TYPES, values: values, setValue: updateBusType, required: true }), busType && busType !== BUS_TYPES[0] && jsx(CheckToggle, { label: "Do you need local airport transfers?", name: "buslocalairporttransfers", values: values, setValue: setValue }), jsxs(FormRow, { columns: 3, children: [jsx(Field, { label: "Pickup Date", name: "buspickupdate", values: values, setValue: setValue, type: "date", min: textValue(values.tripstartdate), maxDate: textValue(values.tripreturndate), required: true }), jsx(Field, { label: "Pickup Time", name: "buspickuptime", values: values, setValue: setValue, type: "time", required: true }), jsx(Field, { label: "# of Buses", name: "numbuses", values: values, setValue: setValue, type: "number", min: 1, max: 99, required: true })] }), jsx(Field, { label: "Motorcoach/Airport Pickup Location", name: "buspickuplocation", values: values, setValue: setValue, required: true }), jsxs("div", { className: styles$9.destinationList, children: [jsx("span", { className: styles$9.label, children: "Destinations *" }), Array.from({ length: destinations }, (_, index) => jsxs("div", { className: styles$9.destinationRow, children: [jsx(Field, { label: `Destination ${index + 1}`, name: destinationName(index), values: values, setValue: setValue, placeholder: `Destination ${index + 1}`, required: true }), destinations > 1 && jsx(Button, { type: "button", size: "sm", variant: "outline", square: true, "aria-label": `Delete Destination ${index + 1}`, onClick: () => deleteDestination(index), children: jsx(TrashIcon$2, { size: 16 }) })] }, index)), destinations < 4 && jsx("div", { children: jsx(Button, { type: "button", size: "sm", variant: "secondary", rightIcon: jsx(PlusIcon$2, { size: 16 }), onClick: () => setDestinations((current) => current + 1), children: "Add Destination" }) })] }), busType === BUS_TYPES[1] && jsx(CheckToggle, { label: "Are you flying back from a different airport than you flew in to?", name: "busdifferentairport", values: values, setValue: setValue }), jsxs(FormRow, { columns: 2, children: [jsx(Field, { label: "Return / Drop Off Date", name: "busreturndate", values: values, setValue: setValue, type: "date", min: textValue(values.buspickupdate) || textValue(values.tripstartdate), maxDate: textValue(values.tripreturndate), required: true }), jsx(Field, { label: "Return / Drop Off Time", name: "busreturntime", values: values, setValue: setValue, type: "time", required: true })] }), jsx(Field, { label: "Motorcoach/Airport Dropoff Location", name: "busdropofflocation", values: values, setValue: setValue, required: true }), jsx(Field, { label: "General Notes on Bus Charter Request", name: "busdetails", values: values, setValue: setValue, multiline: true })] });
|
|
2735
2740
|
};
|
|
2736
|
-
const SummaryRow = ({ label, value }) => !value ? null : jsxs("div", { className: styles$
|
|
2741
|
+
const SummaryRow = ({ label, value }) => !value ? null : jsxs("div", { className: styles$9.summaryRow, children: [jsx("span", { children: label }), jsx("strong", { children: String(value) })] });
|
|
2737
2742
|
const RequestSummary = ({ values, enabled }) => {
|
|
2738
2743
|
const sections = [
|
|
2739
2744
|
enabled.air && { key: 'air', title: 'Commercial Air Request', rows: [['Flight Type', values.airmultiplesegments], ['Departure Airport', values.departlocation], ['Departure Date', values.departdate], ['Arrival Airport', values.arrivelocation]] },
|
|
@@ -2743,7 +2748,7 @@ const RequestSummary = ({ values, enabled }) => {
|
|
|
2743
2748
|
enabled.busneeded && { key: 'busneeded', title: 'Bus Charter Request', rows: [['Charter Bus Type', values.bustype], ['Number of Buses', values.numbuses], ['Pickup Location', values.buspickuplocation], ['Pickup Date', values.buspickupdate], ['Return Date', values.busreturndate]] },
|
|
2744
2749
|
].filter(Boolean);
|
|
2745
2750
|
const populated = sections.filter((section) => section.rows.some(([, value]) => Boolean(value)));
|
|
2746
|
-
return jsxs("div", { className: styles$
|
|
2751
|
+
return jsxs("div", { className: styles$9.summaryCard, children: [jsx("h2", { children: "Request Summary" }), populated.map((section) => jsxs("section", { className: styles$9.summarySection, children: [jsx("h3", { children: section.title }), section.rows.map(([label, value]) => jsx(SummaryRow, { label: label, value: value }, label))] }, section.key)), !populated.length && jsx("p", { className: styles$9.emptySummary, children: "No services selected" })] });
|
|
2747
2752
|
};
|
|
2748
2753
|
const GroupTravelRequestPage = ({ eventName = 'New Trip', totalPages = 1, onSubmit, onCancel, onChange, initialValues = {}, contacts = [], cateringOptions = DEFAULT_CATERING, schoolAddress = '', services = DEFAULT_SERVICES, summarySections, className = '', }) => {
|
|
2749
2754
|
const [currentPage, setCurrentPage] = useState(1);
|
|
@@ -2801,12 +2806,12 @@ const GroupTravelRequestPage = ({ eventName = 'New Trip', totalPages = 1, onSubm
|
|
|
2801
2806
|
setValue(`${field}phone`, contact?.phone ?? '');
|
|
2802
2807
|
setValue(`${field}email`, contact?.email ?? '');
|
|
2803
2808
|
};
|
|
2804
|
-
const section = (key, title, icon, body) => enabled[key] && (jsx("div", { id: key, className: styles$
|
|
2805
|
-
return jsxs("form", { className: `${styles$
|
|
2809
|
+
const section = (key, title, icon, body) => enabled[key] && (jsx("div", { id: key, className: styles$9.serviceSection, "data-mobile-active": activeService === key, children: jsx(FormSection, { title: title, icon: icon, status: key === 'general' ? undefined : 'not-submitted', children: body }) }));
|
|
2810
|
+
return jsxs("form", { className: `${styles$9.page} ${className}`, onSubmit: submit, "aria-label": "Group Travel Request form", children: [jsx("header", { className: styles$9.pageHeader, children: jsxs("h1", { children: ["Group Travel Request ", totalPages > 1 && jsxs("span", { children: ["(", currentPage, "/", totalPages, ")"] }), " ", jsxs("span", { children: ["\u2013 ", eventName] })] }) }), jsxs("div", { className: styles$9.mobileTabs, children: [jsx("button", { type: "button", className: activeTab === 'form' ? styles$9.activeTab : '', onClick: () => setActiveTab('form'), children: "Request Form" }), jsx("button", { type: "button", className: activeTab === 'summary' ? styles$9.activeTab : '', onClick: () => setActiveTab('summary'), children: "Summary" })] }), activeTab === 'form' && jsx("div", { className: styles$9.mobileServices, children: services.map((service) => jsxs("button", { type: "button", className: activeService === service.key ? styles$9.activeService : '', onClick: () => setActiveService((service.key === 'bus' ? 'busneeded' : service.key)), children: [service.icon, jsx("span", { children: service.label })] }, service.key)) }), jsxs("div", { className: styles$9.workspace, children: [jsxs("aside", { className: styles$9.serviceSidebar, children: [jsx(ServiceToggleList, { services: services, enabledServices: enabled, onToggle: toggleService, onClick: (key) => document.getElementById(key)?.scrollIntoView({ behavior: 'smooth', block: 'start' }) }), jsxs("div", { className: styles$9.tripEvents, children: [jsx("h3", { children: "Trip Events" }), jsxs("p", { children: [jsx(CalendarIcon$1, { size: 17 }), " ", eventName] })] })] }), jsxs("main", { className: `${styles$9.formMain} ${activeTab !== 'form' ? styles$9.mobileHidden : ''}`, children: [validationMessage && jsx(Alert, { variant: "error", children: validationMessage }), activeService !== 'general' && !enabled[activeService] && jsxs("div", { className: styles$9.mobileEnable, children: [jsx("span", { children: "Enable Service" }), jsx(Toggle, { "aria-label": `Enable ${activeService}`, checked: false, onChange: (checked) => toggleService(activeService, checked), size: "sm" })] }), section('general', 'General Details', jsx(EventsIcon, {}), jsxs(Fragment, { children: [jsx(Field, { label: "Travel Party Size", name: "attendees", values: values, setValue: setValue, type: "number", min: 1, max: 999, note: "For Commercial Air requests, begin with the largest expected travel party.", required: true }), jsxs(FormRow, { columns: 2, children: [jsx(Field, { label: "Trip Start", name: "tripstartdate", values: values, setValue: setValue, type: "date", required: true }), jsx(Field, { label: "Trip Return", name: "tripreturndate", values: values, setValue: setValue, type: "date", min: textValue(values.tripstartdate), required: true })] }), jsxs("div", { className: styles$9.contactGroup, children: [jsx("span", { className: styles$9.label, children: "Booking Contact *" }), jsx(Field, { label: "Full Name", name: "bookingcontact", values: values, setValue: setValue, disabled: true }), jsxs(FormRow, { columns: 2, children: [jsx(Field, { label: "Phone Number", name: "bookingcontactphone", values: values, setValue: setValue, disabled: true }), jsx(Field, { label: "Email Address", name: "bookingcontactemail", values: values, setValue: setValue, type: "email", disabled: true })] })] }), jsx(Field, { label: "Request Email CC", name: "ccemail", values: values, setValue: setValue, type: "email", note: "Email addresses, comma delimited." }), jsx(Field, { label: "Main Travel Contact", name: "travelcontactid", values: values, setValue: (_name, value) => selectContact('travelcontact', value), options: contactOptions, required: true }), values.travelcontact && jsxs(FormRow, { columns: 2, children: [jsx(Field, { label: "Main Contact Phone", name: "travelcontactphone", values: values, setValue: setValue, disabled: true }), jsx(Field, { label: "Main Contact Email", name: "travelcontactemail", values: values, setValue: setValue, disabled: true })] }), jsx(Field, { label: "Alternate Travel Contact", name: "alternatetravelcontactid", values: values, setValue: (_name, value) => selectContact('alternatetravelcontact', value), options: contactOptions }), values.alternatetravelcontact && jsxs(FormRow, { columns: 2, children: [jsx(Field, { label: "Alternate Contact Phone", name: "alternatetravelcontactphone", values: values, setValue: setValue, disabled: true }), jsx(Field, { label: "Alternate Contact Email", name: "alternatetravelcontactemail", values: values, setValue: setValue, disabled: true })] }), jsx(YesNo, { label: "Is this request for an elimination event or tournament that could require early departure?", name: "tournamenttripelimination", values: values, setValue: setValue }), jsx(Field, { label: "General Notes Regarding This Trip", name: "notes", values: values, setValue: setValue, multiline: true })] })), section('air', 'Commercial Air Request', jsx(PlaneIcon$3, { size: 24 }), jsx(FlightRequest, { prefix: "air", values: values, setValue: setValue, cateringOptions: cateringOptions })), section('charter', 'Charter Air Request', jsx(PlaneIcon$3, { size: 24 }), jsx(FlightRequest, { prefix: "charter", values: values, setValue: setValue, cateringOptions: cateringOptions })), section('hotel', 'Hotel Request', jsx(HotelIcon$3, { size: 24 }), jsx(HotelRequest, { values: values, setValue: setValue })), section('ground', 'Vehicle Rental Request', jsx(CarIcon$1, { size: 24 }), jsx(VehicleRentalRequest, { values: values, setValue: setValue })), section('busneeded', 'Bus Charter Request', jsx(BusIcon$2, { size: 24 }), jsx(BusRequest, { values: values, setValue: setValue, schoolAddress: schoolAddress }))] }), jsx("aside", { className: `${styles$9.summarySidebar} ${activeTab !== 'summary' ? styles$9.summaryMobileHidden : ''}`, children: jsx(RequestSummary, { values: values, enabled: enabled }) })] }), jsxs("footer", { className: styles$9.pageFooter, children: [jsx(Button, { type: "button", variant: "secondary", onClick: previous, children: currentPage === 1 ? totalPages > 1 ? 'Cancel All' : 'Cancel' : 'Previous' }), totalPages > 1 && jsx("div", { className: styles$9.pageButtons, children: Array.from({ length: totalPages }, (_, index) => jsx("button", { type: "button", className: currentPage === index + 1 ? styles$9.currentPage : '', disabled: index + 1 > currentPage, onClick: () => setCurrentPage(index + 1), children: index + 1 }, index)) }), jsx(Button, { type: "submit", children: currentPage === totalPages ? totalPages > 1 ? 'Submit All' : 'Submit' : 'Next' })] })] });
|
|
2806
2811
|
};
|
|
2807
2812
|
GroupTravelRequestPage.displayName = 'GroupTravelRequestPage';
|
|
2808
2813
|
|
|
2809
|
-
var styles$
|
|
2814
|
+
var styles$8 = {"page":"IndividualTravelPage-module_page__4nshX","header":"IndividualTravelPage-module_header__2cECC","title":"IndividualTravelPage-module_title__DQ26Y","tabsContainer":"IndividualTravelPage-module_tabsContainer__O0d2o","tabs":"IndividualTravelPage-module_tabs__IY24z","tab":"IndividualTravelPage-module_tab__ZmAOW","active":"IndividualTravelPage-module_active__Pgl5K","tabCount":"IndividualTravelPage-module_tabCount__ZCeht","activeCount":"IndividualTravelPage-module_activeCount__Tqyde","exportWrapper":"IndividualTravelPage-module_exportWrapper__-JTJo","exportButton":"IndividualTravelPage-module_exportButton__A7fl-","exportMenu":"IndividualTravelPage-module_exportMenu__DyL7-","exportInfo":"IndividualTravelPage-module_exportInfo__x2Hoz","filters":"IndividualTravelPage-module_filters__5IzR1","searchWrapper":"IndividualTravelPage-module_searchWrapper__R5hnF","searchIcon":"IndividualTravelPage-module_searchIcon__OqCpr","searchInput":"IndividualTravelPage-module_searchInput__B9n8z","advancedButton":"IndividualTravelPage-module_advancedButton__7s0pt","advancedActive":"IndividualTravelPage-module_advancedActive__QrQ6D","advancedFilters":"IndividualTravelPage-module_advancedFilters__lb-y3","advancedHeader":"IndividualTravelPage-module_advancedHeader__5xUOz","closeButton":"IndividualTravelPage-module_closeButton__tHiLw","advancedGrid":"IndividualTravelPage-module_advancedGrid__LdXg4","filterField":"IndividualTravelPage-module_filterField__TvLHn","filterActions":"IndividualTravelPage-module_filterActions__-1hYi","applyButton":"IndividualTravelPage-module_applyButton__omOOS","resetButton":"IndividualTravelPage-module_resetButton__NPX4N","pagination":"IndividualTravelPage-module_pagination__D-XBU","paginationInfo":"IndividualTravelPage-module_paginationInfo__4s0T-","paginationControls":"IndividualTravelPage-module_paginationControls__Gsrsp","pageButton":"IndividualTravelPage-module_pageButton__FDBIx","pageInfo":"IndividualTravelPage-module_pageInfo__b2cb5"};
|
|
2810
2815
|
|
|
2811
2816
|
// Default sport options
|
|
2812
2817
|
const defaultSportOptions = [
|
|
@@ -2882,10 +2887,10 @@ const IndividualTravelPage = ({ currentTrips, pastTrips, requestedTrips, sportOp
|
|
|
2882
2887
|
onViewTrip?.(id);
|
|
2883
2888
|
}
|
|
2884
2889
|
};
|
|
2885
|
-
return (jsxs("div", { className: `${styles$
|
|
2890
|
+
return (jsxs("div", { className: `${styles$8.page} ${className || ''}`, children: [jsx("div", { className: styles$8.header, children: jsx("h1", { className: styles$8.title, children: "Individual & Small Group Travel" }) }), jsxs("div", { className: styles$8.tabsContainer, children: [jsx("div", { className: styles$8.tabs, children: tabs.map(tab => (jsxs("button", { className: `${styles$8.tab} ${activeTab === tab.key ? styles$8.active : ''}`, onClick: () => setActiveTab(tab.key), children: [tab.label, jsx("span", { className: `${styles$8.tabCount} ${activeTab === tab.key ? styles$8.activeCount : ''}`, children: tab.count })] }, tab.key))) }), jsxs("div", { className: styles$8.exportWrapper, children: [jsxs("button", { className: styles$8.exportButton, onClick: () => setShowExportMenu(!showExportMenu), children: [jsx("span", { children: "Export" }), jsx(ExportIcon, {})] }), showExportMenu && (jsxs("div", { className: styles$8.exportMenu, children: [hasActiveFilters && (jsxs("div", { className: styles$8.exportInfo, children: [jsx(FilterIcon, {}), jsx("span", { children: "Active filters will be applied to the export." })] })), jsx("button", { onClick: () => { onExport?.('all'); setShowExportMenu(false); }, children: "Export All Trips" }), jsx("button", { onClick: () => { onExport?.('current'); setShowExportMenu(false); }, children: "Export Current & Future" }), jsx("button", { onClick: () => { onExport?.('past'); setShowExportMenu(false); }, children: "Export Past Trips" })] }))] })] }), jsxs("div", { className: styles$8.filters, children: [jsxs("div", { className: styles$8.searchWrapper, children: [jsx("span", { className: styles$8.searchIcon, children: jsx(SearchIcon, {}) }), jsx("input", { type: "text", value: search, onChange: (e) => setSearch(e.target.value), placeholder: "Search traveler, PNR, route\u2026", className: styles$8.searchInput })] }), jsx(FilterChip, { label: "Sport", value: sport, options: sportOptions, onChange: setSport }), jsx(FilterChip, { label: "Traveler", value: traveler, options: computedTravelerOptions, onChange: setTraveler, searchable: true, searchPlaceholder: "Search travelers\u2026", infoMessage: showTravelerScopeInfo ? "Scoped to travelers in your assigned sports." : undefined }), activeTab === 'past' && (jsxs("button", { className: `${styles$8.advancedButton} ${showAdvancedFilters ? styles$8.advancedActive : ''}`, onClick: () => setShowAdvancedFilters(!showAdvancedFilters), children: [jsx(FilterIcon, {}), "Advanced filters"] }))] }), activeTab === 'past' && showAdvancedFilters && (jsxs("div", { className: styles$8.advancedFilters, children: [jsxs("div", { className: styles$8.advancedHeader, children: [jsx("h3", { children: "Advanced filters" }), jsx("button", { className: styles$8.closeButton, onClick: () => setShowAdvancedFilters(false), children: "\u00D7" })] }), jsxs("div", { className: styles$8.advancedGrid, children: [jsxs("div", { className: styles$8.filterField, children: [jsx("label", { children: "Travel Dates" }), jsx("input", { type: "text", placeholder: "Pick a date range" })] }), jsxs("div", { className: styles$8.filterField, children: [jsx("label", { children: "Destination / Routing" }), jsx("input", { type: "text", placeholder: "e.g. LAS, DFW" })] }), jsxs("div", { className: styles$8.filterField, children: [jsx("label", { children: "Vendor" }), jsx("input", { type: "text", placeholder: "e.g. DL, UA" })] }), jsxs("div", { className: styles$8.filterField, children: [jsx("label", { children: "Confirmation / PNR" }), jsx("input", { type: "text", placeholder: "e.g. GA12X7" })] }), jsxs("div", { className: styles$8.filterField, children: [jsx("label", { children: "Ticket Number" }), jsx("input", { type: "text", placeholder: "e.g. 0067123456789" })] }), jsxs("div", { className: styles$8.filterField, children: [jsx("label", { children: "Total / Billed Amount" }), jsx("input", { type: "text", placeholder: "$0.00 \u2013 $0.00" })] }), jsxs("div", { className: styles$8.filterActions, children: [jsx("button", { className: styles$8.applyButton, children: "Apply" }), jsx("button", { className: styles$8.resetButton, children: "Reset" })] })] })] })), jsx(TripTable, { trips: currentData, variant: activeTab, density: density, vendorMode: vendorMode, useServiceColumn: useServiceColumn, onViewTrip: handleViewTrip }), currentData.length > 0 && (jsxs("div", { className: styles$8.pagination, children: [jsxs("div", { className: styles$8.paginationInfo, children: ["Showing 1\u2013", currentData.length, " of ", currentData.length] }), jsxs("div", { className: styles$8.paginationControls, children: [jsx("button", { className: styles$8.pageButton, disabled: true, children: jsx(ChevronLeft, {}) }), jsx("span", { className: styles$8.pageInfo, children: "Page 1 of 1" }), jsx("button", { className: styles$8.pageButton, disabled: true, children: jsx(ChevronRight, {}) })] })] }))] }));
|
|
2886
2891
|
};
|
|
2887
2892
|
|
|
2888
|
-
var styles$
|
|
2893
|
+
var styles$7 = {"page":"InfoCenterPage-module_page__HHBce","breadcrumb":"InfoCenterPage-module_breadcrumb__zv3nA","header":"InfoCenterPage-module_header__qE3KR","headerText":"InfoCenterPage-module_headerText__c8aGS","title":"InfoCenterPage-module_title__apmMY","subtitle":"InfoCenterPage-module_subtitle__ezXCh","stateBlock":"InfoCenterPage-module_stateBlock__qMt4V","stateError":"InfoCenterPage-module_stateError__baFlU","stateText":"InfoCenterPage-module_stateText__N4Uh8","tabs":"InfoCenterPage-module_tabs__HpsCQ","tab":"InfoCenterPage-module_tab__3gKz5","tabActive":"InfoCenterPage-module_tabActive__GJSm9","tabAlert":"InfoCenterPage-module_tabAlert__y642s","grid":"InfoCenterPage-module_grid__-9ra8","card":"InfoCenterPage-module_card__B-coQ","cardAlert":"InfoCenterPage-module_cardAlert__Vwbal","categoryBadge":"InfoCenterPage-module_categoryBadge__wBXtL","categoryAlert":"InfoCenterPage-module_categoryAlert__GhwXY","cardTitle":"InfoCenterPage-module_cardTitle__h8Wb6","cardBody":"InfoCenterPage-module_cardBody__aH8dq","readMore":"InfoCenterPage-module_readMore__oK2fh","editButton":"InfoCenterPage-module_editButton__cpPSU","modalContent":"InfoCenterPage-module_modalContent__BIJPj","articleText":"InfoCenterPage-module_articleText__ch-fl","articleHtml":"InfoCenterPage-module_articleHtml__-DcJ-","externalLink":"InfoCenterPage-module_externalLink__E-upr"};
|
|
2889
2894
|
|
|
2890
2895
|
const CATEGORY_META = {
|
|
2891
2896
|
Alert: { label: 'Alert', icon: WarningIcon$1, alert: true },
|
|
@@ -2903,7 +2908,7 @@ const CATEGORY_ORDER = ['Alert', 'General', 'Air', 'Car', 'Hotel', 'Policy', 'ST
|
|
|
2903
2908
|
const ArticleCard = ({ article, isAdmin, onOpen, onEdit }) => {
|
|
2904
2909
|
const meta = metaFor(article.category);
|
|
2905
2910
|
const CategoryIcon = meta.icon;
|
|
2906
|
-
return (jsxs("div", { className: [styles$
|
|
2911
|
+
return (jsxs("div", { className: [styles$7.card, meta.alert ? styles$7.cardAlert : ''].filter(Boolean).join(' '), children: [jsxs("span", { className: [styles$7.categoryBadge, meta.alert ? styles$7.categoryAlert : ''].filter(Boolean).join(' '), children: [jsx(CategoryIcon, { size: 13 }), meta.label] }), jsx("h3", { className: styles$7.cardTitle, children: article.title }), article.body && jsx("p", { className: styles$7.cardBody, children: article.body }), jsxs("button", { type: "button", className: styles$7.readMore, onClick: () => onOpen(article), children: ["Read more", jsx(ChevronRightIcon$1, { size: 14 })] }), isAdmin && (jsx("button", { type: "button", className: styles$7.editButton, onClick: () => onEdit?.(article), title: "Edit article", "aria-label": "Edit article", children: jsx(EditIcon$2, { size: 14 }) }))] }));
|
|
2907
2912
|
};
|
|
2908
2913
|
/**
|
|
2909
2914
|
* InfoCenterPage - Info Center article browser
|
|
@@ -2956,23 +2961,23 @@ const InfoCenterPage = ({ title = 'Info Center', accountName, articles = [], sta
|
|
|
2956
2961
|
};
|
|
2957
2962
|
const modalMeta = modalArticle ? metaFor(modalArticle.category) : null;
|
|
2958
2963
|
const ModalCategoryIcon = modalMeta?.icon;
|
|
2959
|
-
return (jsxs("div", { className: [styles$
|
|
2964
|
+
return (jsxs("div", { className: [styles$7.page, className].filter(Boolean).join(' '), children: [showBreadcrumb && (jsxs("nav", { className: styles$7.breadcrumb, "aria-label": "Breadcrumb", children: [jsxs("a", { href: homeHref, children: [jsx(HomeIcon, { size: 14 }), "Home"] }), jsx("span", { children: "/" }), jsx("span", { children: "Info Center" })] })), jsxs("div", { className: styles$7.header, children: [jsxs("div", { className: styles$7.headerText, children: [jsx("h1", { className: styles$7.title, children: title }), accountName && (jsxs("p", { className: styles$7.subtitle, children: ["Travel resources and program information for ", accountName, "."] }))] }), isAdmin && (jsxs(Button, { variant: "primary", size: "sm", onClick: onAddArticle, children: [jsx(PlusIcon$2, { size: 15 }), "Add Article"] }))] }), pageState === 'loading' && (jsxs("div", { className: styles$7.stateBlock, children: [jsx(Spinner, { size: "md" }), jsx("span", { children: "Loading\u2026" })] })), pageState === 'error' && (jsxs("div", { className: [styles$7.stateBlock, styles$7.stateError].join(' '), children: [jsx(WarningIcon$1, { size: 28 }), jsx("p", { className: styles$7.stateText, children: "Unable to load Info Center resources." })] })), pageState === 'empty' && (jsxs("div", { className: styles$7.stateBlock, children: [jsx(InfoIcon$1, { size: 28 }), jsx("p", { className: styles$7.stateText, children: "No resources available." })] })), pageState === 'data' && (jsxs(Fragment, { children: [jsxs("div", { className: styles$7.tabs, role: "tablist", "aria-label": "Article categories", children: [jsxs("button", { type: "button", role: "tab", "aria-selected": activeCategory === 'All', onClick: () => setActiveCategory('All'), className: [styles$7.tab, activeCategory === 'All' ? styles$7.tabActive : ''].filter(Boolean).join(' '), children: [jsx(GridIcon, { size: 15 }), "All"] }), categories.map((cat) => {
|
|
2960
2965
|
const m = metaFor(cat);
|
|
2961
2966
|
const TabIcon = m.icon;
|
|
2962
2967
|
const isActive = activeCategory === cat;
|
|
2963
2968
|
return (jsxs("button", { type: "button", role: "tab", "aria-selected": isActive, onClick: () => setActiveCategory(cat), className: [
|
|
2964
|
-
styles$
|
|
2965
|
-
isActive ? styles$
|
|
2966
|
-
m.alert ? styles$
|
|
2969
|
+
styles$7.tab,
|
|
2970
|
+
isActive ? styles$7.tabActive : '',
|
|
2971
|
+
m.alert ? styles$7.tabAlert : '',
|
|
2967
2972
|
]
|
|
2968
2973
|
.filter(Boolean)
|
|
2969
2974
|
.join(' '), children: [jsx(TabIcon, { size: 15 }), m.label] }, cat));
|
|
2970
|
-
})] }), filtered.length === 0 ? (jsxs("div", { className: styles$
|
|
2975
|
+
})] }), filtered.length === 0 ? (jsxs("div", { className: styles$7.stateBlock, children: [jsx(InfoIcon$1, { size: 24 }), jsx("p", { className: styles$7.stateText, children: "No resources in this category." })] })) : (jsx("div", { className: styles$7.grid, children: filtered.map((article) => (jsx(ArticleCard, { article: article, isAdmin: isAdmin, onOpen: handleOpen, onEdit: onEditArticle }, article.id))) }))] })), jsx(Modal, { isOpen: modalArticle !== null, onClose: () => setModalArticle(null), title: modalArticle?.title, size: "lg", footer: modalArticle?.href ? (jsxs("a", { href: modalArticle.href, target: "_blank", rel: "noopener noreferrer", className: styles$7.externalLink, children: ["Open external resource", jsx(ArrowUpRightIcon, { size: 14 })] })) : undefined, children: modalArticle && (jsxs("div", { className: styles$7.modalContent, children: [modalMeta && ModalCategoryIcon && (jsxs("span", { className: [styles$7.categoryBadge, modalMeta.alert ? styles$7.categoryAlert : '']
|
|
2971
2976
|
.filter(Boolean)
|
|
2972
|
-
.join(' '), children: [jsx(ModalCategoryIcon, { size: 13 }), modalMeta.label] })), modalArticle.fullText ? (jsx("div", { className: styles$
|
|
2977
|
+
.join(' '), children: [jsx(ModalCategoryIcon, { size: 13 }), modalMeta.label] })), modalArticle.fullText ? (jsx("div", { className: styles$7.articleHtml, dangerouslySetInnerHTML: { __html: modalArticle.fullText } })) : (jsx("p", { className: styles$7.articleText, children: modalArticle.body }))] })) })] }));
|
|
2973
2978
|
};
|
|
2974
2979
|
|
|
2975
|
-
var styles$
|
|
2980
|
+
var styles$6 = {"page":"NotFoundPage-module_page__Wg8P8","card":"NotFoundPage-module_card__pgJYC","illustration":"NotFoundPage-module_illustration__uOy-Q","errorCode":"NotFoundPage-module_errorCode__2uerJ","title":"NotFoundPage-module_title__8AOy7","message":"NotFoundPage-module_message__PcyZ-","action":"NotFoundPage-module_action__7rQHt"};
|
|
2976
2981
|
|
|
2977
2982
|
const DefaultIllustration = () => (jsxs("svg", { width: "120", height: "120", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "1", children: [jsx("circle", { cx: "12", cy: "12", r: "10" }), jsx("line", { x1: "15", y1: "9", x2: "9", y2: "15" }), jsx("line", { x1: "9", y1: "9", x2: "15", y2: "15" })] }));
|
|
2978
2983
|
/**
|
|
@@ -2986,13 +2991,42 @@ const DefaultIllustration = () => (jsxs("svg", { width: "120", height: "120", vi
|
|
|
2986
2991
|
*/
|
|
2987
2992
|
const NotFoundPage = ({ errorCode = '404', title = 'Page Not Found', message = 'The page you are looking for does not exist or you do not have permission to access it.', action, illustration, className = '', }) => {
|
|
2988
2993
|
const pageClasses = [
|
|
2989
|
-
styles$
|
|
2994
|
+
styles$6.page,
|
|
2990
2995
|
className,
|
|
2991
2996
|
].filter(Boolean).join(' ');
|
|
2992
|
-
return (jsx("div", { className: pageClasses, children: jsxs("div", { className: styles$
|
|
2997
|
+
return (jsx("div", { className: pageClasses, children: jsxs("div", { className: styles$6.card, children: [jsx("div", { className: styles$6.illustration, children: illustration || jsx(DefaultIllustration, {}) }), jsx("h1", { className: styles$6.errorCode, children: errorCode }), jsx("h2", { className: styles$6.title, children: title }), jsx("p", { className: styles$6.message, children: message }), action && (jsx("div", { className: styles$6.action, children: action }))] }) }));
|
|
2993
2998
|
};
|
|
2994
2999
|
NotFoundPage.displayName = 'NotFoundPage';
|
|
2995
3000
|
|
|
3001
|
+
var styles$5 = {"page":"RosterProgramNumbersPage-module_page__eNDG8","header":"RosterProgramNumbersPage-module_header__1YtCr","heading":"RosterProgramNumbersPage-module_heading__6tBIK","tableWrap":"RosterProgramNumbersPage-module_tableWrap__l0smr","table":"RosterProgramNumbersPage-module_table__6UGEu","traveler":"RosterProgramNumbersPage-module_traveler__7ZbBS","supplier":"RosterProgramNumbersPage-module_supplier__EEXuR","inputCell":"RosterProgramNumbersPage-module_inputCell__OaiTN","empty":"RosterProgramNumbersPage-module_empty__iFweL","footer":"RosterProgramNumbersPage-module_footer__p4K-j"};
|
|
3002
|
+
|
|
3003
|
+
const RosterProgramNumbersPage = ({ programs, loading = false, saving = false, onBack, onSubmit, }) => {
|
|
3004
|
+
const initialValues = useMemo(() => Object.fromEntries(programs.map((program) => [String(program.id), program.accountNumber])), [programs]);
|
|
3005
|
+
const [values, setValues] = useState(initialValues);
|
|
3006
|
+
useEffect(() => {
|
|
3007
|
+
setValues((current) => {
|
|
3008
|
+
const keys = Object.keys(initialValues);
|
|
3009
|
+
const unchanged = keys.length === Object.keys(current).length &&
|
|
3010
|
+
keys.every((key) => current[key] === initialValues[key]);
|
|
3011
|
+
return unchanged ? current : initialValues;
|
|
3012
|
+
});
|
|
3013
|
+
}, [initialValues]);
|
|
3014
|
+
const submit = (event) => {
|
|
3015
|
+
event.preventDefault();
|
|
3016
|
+
void onSubmit?.(programs.map((program) => ({
|
|
3017
|
+
...program,
|
|
3018
|
+
accountNumber: values[String(program.id)] ?? '',
|
|
3019
|
+
})));
|
|
3020
|
+
};
|
|
3021
|
+
return (jsxs("section", { className: styles$5.page, "data-test": "roster-program-numbers-page", children: [jsxs("header", { className: styles$5.header, children: [jsxs("div", { className: styles$5.heading, children: [jsx("h1", { children: "Edit Program Numbers" }), jsx("p", { children: "Update existing traveler loyalty-program numbers without changing the rest of the roster." })] }), jsx(Button, { type: "button", variant: "outline", size: "sm", "data-test": "program-numbers-back", onClick: onBack, children: "Back to Roster" })] }), jsx(Module, { title: "Roster Program Numbers", useToggle: false, children: jsxs("form", { onSubmit: submit, "data-test": "program-numbers-form", children: [loading ? (jsx("div", { className: styles$5.empty, role: "status", children: "Loading roster program numbers..." })) : programs.length ? (jsx("div", { className: styles$5.tableWrap, children: jsxs("table", { className: styles$5.table, children: [jsx("thead", { children: jsxs("tr", { children: [jsx("th", { children: "Traveler" }), jsx("th", { children: "Program" }), jsx("th", { children: "Program Number" })] }) }), jsx("tbody", { children: programs.map((program) => (jsxs("tr", { "data-test": `program-number-row-${program.id}`, children: [jsx("td", { children: jsxs("div", { className: styles$5.traveler, children: [jsx("strong", { children: program.travelerName }), program.travelerType && jsx("span", { children: program.travelerType })] }) }), jsx("td", { children: jsx("span", { className: styles$5.supplier, children: program.supplierName }) }), jsx("td", { className: styles$5.inputCell, children: jsx(Input, { id: `program-number-${program.id}`, "aria-label": `Program number for ${program.travelerName} — ${program.supplierName}`, "data-test": `program-number-input-${program.id}`, value: values[String(program.id)] ?? '', required: true, fullWidth: true, size: "sm", disabled: saving, onChange: (event) => setValues((current) => ({ ...current, [String(program.id)]: event.target.value })) }) })] }, program.id))) })] }) })) : (jsx("div", { className: styles$5.empty, children: "No existing membership programs are available to edit." })), !!programs.length && (jsxs("div", { className: styles$5.footer, children: [jsx(Button, { type: "button", variant: "outline", disabled: saving, onClick: onBack, children: "Cancel" }), jsx(Button, { type: "submit", loading: saving, "data-test": "program-numbers-submit", children: "Submit" })] }))] }) })] }));
|
|
3022
|
+
};
|
|
3023
|
+
RosterProgramNumbersPage.displayName = 'RosterProgramNumbersPage';
|
|
3024
|
+
|
|
3025
|
+
var styles$4 = {"page":"RosterReportsPage-module_page__ZU5hz","header":"RosterReportsPage-module_header__FFSTB","heading":"RosterReportsPage-module_heading__rIwdQ","list":"RosterReportsPage-module_list__9K8tF","report":"RosterReportsPage-module_report__iXROM","details":"RosterReportsPage-module_details__WZ6cT","empty":"RosterReportsPage-module_empty__Nrynv"};
|
|
3026
|
+
|
|
3027
|
+
const RosterReportsPage = ({ reports, runningReportId, onBack, onRun }) => (jsxs("section", { className: styles$4.page, "data-test": "roster-reports-page", children: [jsxs("header", { className: styles$4.header, children: [jsxs("div", { className: styles$4.heading, children: [jsx("h1", { children: "Roster Reports" }), jsx("p", { children: "Run the available reports for the selected team roster." })] }), jsx(Button, { type: "button", variant: "outline", size: "sm", "data-test": "roster-reports-back", onClick: onBack, children: "Back to Roster" })] }), jsx(Module, { title: "Team Reports", useToggle: false, children: reports.length ? (jsx("div", { className: styles$4.list, "data-test": "roster-report-list", children: reports.map((report) => (jsxs("article", { className: styles$4.report, "data-test": `roster-report-${report.id}`, children: [jsxs("div", { className: styles$4.details, children: [jsx("h2", { children: report.title }), report.description && jsx("p", { children: report.description })] }), jsx(Button, { type: "button", variant: "outline", size: "sm", loading: runningReportId === report.id, disabled: Boolean(runningReportId) && runningReportId !== report.id, "data-test": `run-roster-report-${report.id}`, onClick: () => void onRun?.(report), children: "Run Report" })] }, report.id))) })) : (jsx("div", { className: styles$4.empty, children: "No roster reports are currently available." })) })] }));
|
|
3028
|
+
RosterReportsPage.displayName = 'RosterReportsPage';
|
|
3029
|
+
|
|
2996
3030
|
var styles$3 = {"page":"TeamManagementPage-module_page__iRm2r","overview":"TeamManagementPage-module_overview__HDnLX","overviewHeader":"TeamManagementPage-module_overviewHeader__OYpB8","overviewGrid":"TeamManagementPage-module_overviewGrid__u8VZy","contactsColumn":"TeamManagementPage-module_contactsColumn__g-gm8","body":"TeamManagementPage-module_body__10aka","main":"TeamManagementPage-module_main__-lFtT","sidebar":"TeamManagementPage-module_sidebar__u8syG","footer":"TeamManagementPage-module_footer__he9G0"};
|
|
2997
3031
|
|
|
2998
3032
|
const DEFAULT_TABS = [
|
|
@@ -3094,5 +3128,5 @@ const TripDetailPage = ({ header, airSegment, groundSegment, hotelSegment, files
|
|
|
3094
3128
|
};
|
|
3095
3129
|
TripDetailPage.displayName = 'TripDetailPage';
|
|
3096
3130
|
|
|
3097
|
-
export { Accordion, AdministrationPage, AirSegment, Alert, AppLayout, ArrowDownLeftIcon, ArrowUpRightIcon, Avatar, AvatarGroup, Badge, BuildingIcon, BusIcon$2 as BusIcon, Button, CalendarIcon$1 as CalendarIcon, CalendarTypeSelector, CalendarViewSelector, CarIcon$1 as CarIcon, Card, CardBody, CardFooter, CardHeader, CharterManifestPage, CheckIcon$2 as CheckIcon, Checkbox, ChevronDownIcon$1 as ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon$1 as ChevronRightIcon, ChevronUpIcon, CloseIcon, ConfirmModal, ContactList, ContactUsPage, CubeIcon, DashboardIcon, DashboardPage, Datepicker, DocumentIcon, DownloadIcon, Drawer, DrawerBody, DrawerFooter, DrawerHeader, Dropdown, DueDatesDrawer, EditIcon$2 as EditIcon, EyeIcon, FilterChip, FilterIcon$1 as FilterIcon, FormField, FormRow, FormSection, FormStack, GridIcon, GroundSegment, GroupTravelRequestPage, HUB_ADMIN_ITEM, HUB_INDIVIDUAL_TRAVEL_ITEM, HUB_NAV_ITEMS, HomeIcon, HotelIcon$3 as HotelIcon, HotelSegment, HubAppShell, Icons, IndividualTravelPage, InfoCenterPage, InfoIcon$1 as InfoIcon, Input, LightbulbIcon, LimoIcon, LockIcon$1 as LockIcon, LogoIcon, MailIcon, ManifestCapacityStats, ManifestViewToggle, MegaphoneIcon, MembershipPrograms, MenuIcon, Metric, MinusIcon, Modal, ModalFooter, Module, ModuleDivider, ModuleVerticalDivider, NavItem, NotFoundPage, PageBanners, PhoneIcon, PlaneIcon$3 as PlaneIcon, PlusIcon$2 as PlusIcon, PreferencesPanel, PrinterIcon, Progress, ProgressBar, ProgressCircle, RailIcon, RefreshIcon, ReportIcon, RequestFormFooter, RequestFormHeader, RequestFormLayout, RequestSummary$1 as RequestSummary, RosterToolbar, SUPPLIER_TYPE_OPTIONS, SchoolContactForm, SearchField, SearchIcon$1 as SearchIcon, Segment, SegmentedSelector, Select, SelectFilter, ServiceToggle, ServiceToggleList, SettingsIcon, Sidenav, Spinner, StatusBadge, SummarySection, SupplierTypeToggle, Table, Tag, TeamCard, TeamContactsPanel, TeamEquipmentForm, TeamHeader, TeamImportForm, TeamManagementPage, TeamProgramForm, TeamRosterMemberForm, TeamScheduleActions, TeamScheduleCompactTable, TeamScheduleEditor, TeamScheduleExpandedTable, TeamSchedulePage, TeamSubMenu, TeamTravelCalendarCardView, TeamTravelCalendarListView, TeamTravelCalendarPage, TeamTravelCalendarToolbar, TeamTravelCalendarView, TeamUserAccessForm, Textarea, Timepicker, Title, Toggle, Tooltip, Topbar, TrashIcon$2 as TrashIcon, TravelServiceIcon, TravelSummaryMetrics, TravelerForm, TrendDownIcon, TrendUpIcon, TripDetailPage, TripSegment, TripTable, TypeIcon, UploadIcon, UserIcon, UsersIcon$1 as UsersIcon, WarningIcon$1 as WarningIcon, XIcon, formatCompactTripCost, formatTeamScheduleTravelDates, getTeamTravelCalendarPeriodLabel, isTravelDueDateCompleted, moveTeamTravelCalendarPeriod };
|
|
3131
|
+
export { Accordion, AdministrationPage, AirSegment, Alert, AppLayout, ArrowDownLeftIcon, ArrowUpRightIcon, Avatar, AvatarGroup, Badge, BuildingIcon, BusIcon$2 as BusIcon, Button, CalendarIcon$1 as CalendarIcon, CalendarTypeSelector, CalendarViewSelector, CarIcon$1 as CarIcon, Card, CardBody, CardFooter, CardHeader, CharterManifestPage, CheckIcon$2 as CheckIcon, Checkbox, ChevronDownIcon$1 as ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon$1 as ChevronRightIcon, ChevronUpIcon, CloseIcon, ConfirmModal, ContactList, ContactUsPage, CubeIcon, DashboardIcon, DashboardPage, Datepicker, DocumentIcon, DownloadIcon, Drawer, DrawerBody, DrawerFooter, DrawerHeader, Dropdown, DueDatesDrawer, EditIcon$2 as EditIcon, EyeIcon, FilterChip, FilterIcon$1 as FilterIcon, FormField, FormRow, FormSection, FormStack, GridIcon, GroundSegment, GroupTravelRequestPage, HUB_ADMIN_ITEM, HUB_INDIVIDUAL_TRAVEL_ITEM, HUB_NAV_ITEMS, HomeIcon, HotelIcon$3 as HotelIcon, HotelSegment, HubAppShell, Icons, IndividualTravelPage, InfoCenterPage, InfoIcon$1 as InfoIcon, Input, LightbulbIcon, LimoIcon, LockIcon$1 as LockIcon, LogoIcon, MailIcon, ManifestCapacityStats, ManifestViewToggle, MegaphoneIcon, MembershipPrograms, MenuIcon, Metric, MinusIcon, Modal, ModalFooter, Module, ModuleDivider, ModuleVerticalDivider, NavItem, NotFoundPage, PageBanners, PhoneIcon, PlaneIcon$3 as PlaneIcon, PlusIcon$2 as PlusIcon, PreferencesPanel, PrinterIcon, Progress, ProgressBar, ProgressCircle, RailIcon, RefreshIcon, ReportIcon, RequestFormFooter, RequestFormHeader, RequestFormLayout, RequestSummary$1 as RequestSummary, RosterProgramNumbersPage, RosterReportsPage, RosterToolbar, SUPPLIER_TYPE_OPTIONS, SchoolContactForm, SearchField, SearchIcon$1 as SearchIcon, Segment, SegmentedSelector, Select, SelectFilter, ServiceToggle, ServiceToggleList, SettingsIcon, Sidenav, Spinner, StatusBadge, SummarySection, SupplierTypeToggle, Table, Tag, TeamCard, TeamContactsPanel, TeamEquipmentForm, TeamHeader, TeamImportForm, TeamManagementPage, TeamProgramForm, TeamRosterMemberForm, TeamScheduleActions, TeamScheduleCompactTable, TeamScheduleEditor, TeamScheduleExpandedTable, TeamSchedulePage, TeamSubMenu, TeamTravelCalendarCardView, TeamTravelCalendarListView, TeamTravelCalendarPage, TeamTravelCalendarToolbar, TeamTravelCalendarView, TeamUserAccessForm, Textarea, Timepicker, Title, Toggle, Tooltip, Topbar, TrashIcon$2 as TrashIcon, TravelServiceIcon, TravelSummaryMetrics, TravelerForm, TrendDownIcon, TrendUpIcon, TripDetailPage, TripSegment, TripTable, TypeIcon, UploadIcon, UserIcon, UsersIcon$1 as UsersIcon, WarningIcon$1 as WarningIcon, XIcon, formatCompactTripCost, formatTeamScheduleDueDate, formatTeamScheduleTravelDates, getTeamTravelCalendarPeriodLabel, isTravelDueDateCompleted, moveTeamTravelCalendarPeriod };
|
|
3098
3132
|
//# sourceMappingURL=index.esm.js.map
|