@flamingo-stack/openframe-frontend-core 0.0.352 → 0.0.353-snapshot.20260701190625
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/{chunk-K2NJ5VHQ.cjs → chunk-2RX6DW5A.cjs} +73 -73
- package/dist/{chunk-K2NJ5VHQ.cjs.map → chunk-2RX6DW5A.cjs.map} +1 -1
- package/dist/{chunk-66D3JL6J.js → chunk-3MUALDLX.js} +5 -5
- package/dist/{chunk-HPVOWKIO.cjs → chunk-3XNJWYLX.cjs} +15 -15
- package/dist/{chunk-HPVOWKIO.cjs.map → chunk-3XNJWYLX.cjs.map} +1 -1
- package/dist/{chunk-TM455OW5.js → chunk-4XFFHXCQ.js} +6 -6
- package/dist/{chunk-IM5HXLFT.js → chunk-5CTJCJV3.js} +3 -3
- package/dist/{chunk-RTKRXPPG.cjs → chunk-5RYGC2HA.cjs} +29 -29
- package/dist/{chunk-RTKRXPPG.cjs.map → chunk-5RYGC2HA.cjs.map} +1 -1
- package/dist/{chunk-FQ4VGHPO.js → chunk-AN7YCTF4.js} +3 -3
- package/dist/{chunk-7CTSKYAV.js → chunk-BWT6O7K5.js} +2 -2
- package/dist/{chunk-GGCOLMNS.js → chunk-DFZ74LGW.js} +3 -3
- package/dist/{chunk-RD3HIB25.cjs → chunk-GPX5I7FT.cjs} +2 -2
- package/dist/{chunk-FPAF4JHM.js.map → chunk-GPX5I7FT.cjs.map} +1 -1
- package/dist/{chunk-3SYTPXCP.cjs → chunk-HD4S7ITV.cjs} +40 -40
- package/dist/{chunk-3SYTPXCP.cjs.map → chunk-HD4S7ITV.cjs.map} +1 -1
- package/dist/{chunk-3QWEET5C.js → chunk-HEXR3TGX.js} +2 -2
- package/dist/{chunk-T2ARJIH6.cjs → chunk-J5RQ4T5L.cjs} +70 -70
- package/dist/{chunk-T2ARJIH6.cjs.map → chunk-J5RQ4T5L.cjs.map} +1 -1
- package/dist/{chunk-FPAF4JHM.js → chunk-JGAAUUD7.js} +2 -2
- package/dist/chunk-JGAAUUD7.js.map +1 -0
- package/dist/{chunk-42PSJKMY.cjs → chunk-LNJ4QIAN.cjs} +31 -31
- package/dist/{chunk-42PSJKMY.cjs.map → chunk-LNJ4QIAN.cjs.map} +1 -1
- package/dist/{chunk-JQGLBAGS.js → chunk-LPJKRZRD.js} +2 -2
- package/dist/{chunk-IHXJKIFM.cjs → chunk-MHWK6CDS.cjs} +19 -19
- package/dist/{chunk-IHXJKIFM.cjs.map → chunk-MHWK6CDS.cjs.map} +1 -1
- package/dist/{chunk-M247JWGY.js → chunk-NJ4R2IJY.js} +6 -6
- package/dist/{chunk-DY4Y7QQB.cjs → chunk-NJRZK3KL.cjs} +39 -39
- package/dist/{chunk-DY4Y7QQB.cjs.map → chunk-NJRZK3KL.cjs.map} +1 -1
- package/dist/{chunk-ZRLPXSZC.cjs → chunk-O6HI537F.cjs} +12 -12
- package/dist/{chunk-ZRLPXSZC.cjs.map → chunk-O6HI537F.cjs.map} +1 -1
- package/dist/{chunk-QP7TLRLH.cjs → chunk-OQ75ZMB7.cjs} +511 -459
- package/dist/chunk-OQ75ZMB7.cjs.map +1 -0
- package/dist/{chunk-FU5KF6MA.cjs → chunk-RERV3ALE.cjs} +7 -7
- package/dist/{chunk-FU5KF6MA.cjs.map → chunk-RERV3ALE.cjs.map} +1 -1
- package/dist/{chunk-JKJO7HVH.cjs → chunk-RYROZ7HM.cjs} +3 -3
- package/dist/{chunk-JKJO7HVH.cjs.map → chunk-RYROZ7HM.cjs.map} +1 -1
- package/dist/{chunk-ONMA32BY.js → chunk-SH5ZPAVK.js} +4 -4
- package/dist/{chunk-N7BREY67.js → chunk-SJ3O2463.js} +5 -5
- package/dist/{chunk-HSZJGPVA.js → chunk-SJBFKX6U.js} +69 -17
- package/dist/{chunk-HSZJGPVA.js.map → chunk-SJBFKX6U.js.map} +1 -1
- package/dist/{chunk-KYCZ4ISB.js → chunk-U5MQW3PH.js} +2 -2
- package/dist/{chunk-ED72ZQV7.cjs → chunk-XXVNJDZV.cjs} +5 -5
- package/dist/{chunk-ED72ZQV7.cjs.map → chunk-XXVNJDZV.cjs.map} +1 -1
- package/dist/components/case-studies/index.cjs +9 -9
- package/dist/components/case-studies/index.js +3 -3
- package/dist/components/chat/index.cjs +3 -3
- package/dist/components/chat/index.js +2 -2
- package/dist/components/contact/index.cjs +4 -4
- package/dist/components/contact/index.js +3 -3
- package/dist/components/docs/index.cjs +6 -6
- package/dist/components/docs/index.js +5 -5
- package/dist/components/embeds/index.cjs +4 -4
- package/dist/components/embeds/index.js +3 -3
- package/dist/components/faq/index.cjs +5 -5
- package/dist/components/faq/index.js +4 -4
- package/dist/components/features/index.cjs +3 -3
- package/dist/components/features/index.js +2 -2
- package/dist/components/features/time-tracker/index.d.ts +1 -1
- package/dist/components/features/time-tracker/index.d.ts.map +1 -1
- package/dist/components/features/time-tracker/time-tracker-panel.d.ts +1 -1
- package/dist/components/features/time-tracker/time-tracker-panel.d.ts.map +1 -1
- package/dist/components/features/time-tracker/types.d.ts +19 -0
- package/dist/components/features/time-tracker/types.d.ts.map +1 -1
- package/dist/components/help-center-pages/index.cjs +22 -22
- package/dist/components/help-center-pages/index.js +13 -13
- package/dist/components/index.cjs +124 -124
- package/dist/components/index.js +11 -11
- package/dist/components/navigation/index.cjs +3 -3
- package/dist/components/navigation/index.js +2 -2
- package/dist/components/onboarding-guides/index.cjs +7 -7
- package/dist/components/onboarding-guides/index.js +6 -6
- package/dist/components/related-content/index.cjs +5 -5
- package/dist/components/related-content/index.js +4 -4
- package/dist/components/tickets/index.cjs +6 -6
- package/dist/components/tickets/index.js +5 -5
- package/dist/components/ui/index.cjs +3 -3
- package/dist/components/ui/index.js +2 -2
- package/dist/hooks/index.cjs +2 -2
- package/dist/hooks/index.js +1 -1
- package/dist/index.cjs +3 -3
- package/dist/index.js +2 -2
- package/dist/utils/index.cjs +1 -1
- package/dist/utils/index.cjs.map +1 -1
- package/dist/utils/index.js +1 -1
- package/dist/utils/index.js.map +1 -1
- package/dist/utils/platform-config.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/components/features/time-tracker/index.ts +1 -0
- package/src/components/features/time-tracker/time-tracker-panel.tsx +75 -13
- package/src/components/features/time-tracker/types.ts +21 -0
- package/src/utils/platform-config.tsx +4 -1
- package/dist/chunk-QP7TLRLH.cjs.map +0 -1
- package/dist/chunk-RD3HIB25.cjs.map +0 -1
- /package/dist/{chunk-66D3JL6J.js.map → chunk-3MUALDLX.js.map} +0 -0
- /package/dist/{chunk-TM455OW5.js.map → chunk-4XFFHXCQ.js.map} +0 -0
- /package/dist/{chunk-IM5HXLFT.js.map → chunk-5CTJCJV3.js.map} +0 -0
- /package/dist/{chunk-FQ4VGHPO.js.map → chunk-AN7YCTF4.js.map} +0 -0
- /package/dist/{chunk-7CTSKYAV.js.map → chunk-BWT6O7K5.js.map} +0 -0
- /package/dist/{chunk-GGCOLMNS.js.map → chunk-DFZ74LGW.js.map} +0 -0
- /package/dist/{chunk-3QWEET5C.js.map → chunk-HEXR3TGX.js.map} +0 -0
- /package/dist/{chunk-JQGLBAGS.js.map → chunk-LPJKRZRD.js.map} +0 -0
- /package/dist/{chunk-M247JWGY.js.map → chunk-NJ4R2IJY.js.map} +0 -0
- /package/dist/{chunk-ONMA32BY.js.map → chunk-SH5ZPAVK.js.map} +0 -0
- /package/dist/{chunk-N7BREY67.js.map → chunk-SJ3O2463.js.map} +0 -0
- /package/dist/{chunk-KYCZ4ISB.js.map → chunk-U5MQW3PH.js.map} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"platform-config.d.ts","sourceRoot":"","sources":["../../src/utils/platform-config.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC/D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAGxD,eAAO,MAAM,aAAa;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GAAE,MAAkB,GAAG,KAAK,CAAC,SAAS,CA4B7G"}
|
package/package.json
CHANGED
|
@@ -5,11 +5,13 @@ import { cn } from '../../../utils/cn'
|
|
|
5
5
|
import { Autocomplete, type AutocompleteOption } from '../../ui/autocomplete'
|
|
6
6
|
import { Button } from '../../ui/button/button'
|
|
7
7
|
import { SplitButton } from '../../ui/button/split-button'
|
|
8
|
+
import { SquareAvatar } from '../../ui/square-avatar'
|
|
8
9
|
import { Tag } from '../../ui/tag'
|
|
9
10
|
import { Textarea } from '../../ui/textarea'
|
|
10
11
|
import {
|
|
11
12
|
ArrowRightUpIcon,
|
|
12
13
|
CheckCircleIcon,
|
|
14
|
+
CheckIcon,
|
|
13
15
|
Chevron02RightIcon,
|
|
14
16
|
ClockHistoryIcon,
|
|
15
17
|
DotsLoaderIcon,
|
|
@@ -21,6 +23,25 @@ import {
|
|
|
21
23
|
import { useTrackerClock } from './use-tracker-clock'
|
|
22
24
|
import type { TimeTrackerData, TimeTrackerEntry, TimeTrackerStatus } from './types'
|
|
23
25
|
|
|
26
|
+
interface CustomerAutocompleteOption extends AutocompleteOption {
|
|
27
|
+
imageUrl?: string
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
function renderCustomerOption(option: AutocompleteOption, isSelected: boolean) {
|
|
31
|
+
const { label, imageUrl } = option as CustomerAutocompleteOption
|
|
32
|
+
return (
|
|
33
|
+
<div className="flex w-full min-w-0 items-center justify-between gap-[var(--spacing-system-xs)]">
|
|
34
|
+
<div className="flex min-w-0 items-center gap-[var(--spacing-system-xs)]">
|
|
35
|
+
<SquareAvatar src={imageUrl} alt={label} fallback={label} size="sm" variant="square" />
|
|
36
|
+
<span className="truncate" title={label}>
|
|
37
|
+
{label}
|
|
38
|
+
</span>
|
|
39
|
+
</div>
|
|
40
|
+
{isSelected && <CheckIcon className="text-ods-accent" size={20} />}
|
|
41
|
+
</div>
|
|
42
|
+
)
|
|
43
|
+
}
|
|
44
|
+
|
|
24
45
|
export interface TimeTrackerPanelProps extends TimeTrackerData {
|
|
25
46
|
onClose: () => void
|
|
26
47
|
className?: string
|
|
@@ -35,6 +56,12 @@ export function TimeTrackerPanel({
|
|
|
35
56
|
onSelectedTicketChange,
|
|
36
57
|
onTicketSearch,
|
|
37
58
|
ticketsLoading,
|
|
59
|
+
customerOptions,
|
|
60
|
+
selectedCustomerId,
|
|
61
|
+
onSelectedCustomerChange,
|
|
62
|
+
onCustomerSearch,
|
|
63
|
+
customersLoading,
|
|
64
|
+
customerLocked,
|
|
38
65
|
notes,
|
|
39
66
|
onNotesChange,
|
|
40
67
|
lastEntries,
|
|
@@ -102,6 +129,23 @@ export function TimeTrackerPanel({
|
|
|
102
129
|
value: t.id,
|
|
103
130
|
}))
|
|
104
131
|
|
|
132
|
+
const showCustomer = !!onSelectedCustomerChange
|
|
133
|
+
const customerAutocompleteOptions: CustomerAutocompleteOption[] = (customerOptions ?? []).map((c) => ({
|
|
134
|
+
label: c.label,
|
|
135
|
+
value: c.id,
|
|
136
|
+
imageUrl: c.imageUrl,
|
|
137
|
+
}))
|
|
138
|
+
const selectedCustomer = customerAutocompleteOptions.find((o) => o.value === selectedCustomerId)
|
|
139
|
+
const customerStartAdornment = selectedCustomer ? (
|
|
140
|
+
<SquareAvatar
|
|
141
|
+
src={selectedCustomer.imageUrl}
|
|
142
|
+
alt={selectedCustomer.label}
|
|
143
|
+
fallback={selectedCustomer.label}
|
|
144
|
+
size="sm"
|
|
145
|
+
variant="square"
|
|
146
|
+
/>
|
|
147
|
+
) : undefined
|
|
148
|
+
|
|
105
149
|
const visibleEntries = lastEntries.slice(0, 3)
|
|
106
150
|
|
|
107
151
|
return (
|
|
@@ -173,19 +217,37 @@ export function TimeTrackerPanel({
|
|
|
173
217
|
)}
|
|
174
218
|
</div>
|
|
175
219
|
|
|
176
|
-
<
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
220
|
+
<div className={cn('grid gap-[var(--spacing-system-m)]', showCustomer && 'grid-cols-2')}>
|
|
221
|
+
<Autocomplete
|
|
222
|
+
value={selectedTicketId}
|
|
223
|
+
onChange={onSelectedTicketChange}
|
|
224
|
+
options={ticketAutocompleteOptions}
|
|
225
|
+
placeholder="Select Ticket"
|
|
226
|
+
loading={ticketsLoading}
|
|
227
|
+
invalid={showFieldError}
|
|
228
|
+
error={showFieldError ? 'Required if no notes added' : undefined}
|
|
229
|
+
disableClientFilter={!!onTicketSearch}
|
|
230
|
+
onInputChange={(value, reason) => {
|
|
231
|
+
if (reason === 'input') onTicketSearch?.(value)
|
|
232
|
+
}}
|
|
233
|
+
/>
|
|
234
|
+
{showCustomer && (
|
|
235
|
+
<Autocomplete
|
|
236
|
+
value={selectedCustomerId ?? null}
|
|
237
|
+
onChange={onSelectedCustomerChange}
|
|
238
|
+
options={customerAutocompleteOptions}
|
|
239
|
+
placeholder="Select Customer"
|
|
240
|
+
loading={customersLoading}
|
|
241
|
+
disabled={customerLocked}
|
|
242
|
+
disableClientFilter={!!onCustomerSearch}
|
|
243
|
+
onInputChange={(value, reason) => {
|
|
244
|
+
if (reason === 'input') onCustomerSearch?.(value)
|
|
245
|
+
}}
|
|
246
|
+
startAdornment={customerStartAdornment}
|
|
247
|
+
renderOption={renderCustomerOption}
|
|
248
|
+
/>
|
|
249
|
+
)}
|
|
250
|
+
</div>
|
|
189
251
|
</div>
|
|
190
252
|
|
|
191
253
|
<Textarea
|
|
@@ -5,6 +5,13 @@ export interface TimeTrackerTicketOption {
|
|
|
5
5
|
label: string
|
|
6
6
|
}
|
|
7
7
|
|
|
8
|
+
export interface TimeTrackerCustomerOption {
|
|
9
|
+
id: string
|
|
10
|
+
label: string
|
|
11
|
+
/** Fully-resolved avatar image URL (the host resolves it). */
|
|
12
|
+
imageUrl?: string
|
|
13
|
+
}
|
|
14
|
+
|
|
8
15
|
export interface TimeTrackerEntry {
|
|
9
16
|
id: string
|
|
10
17
|
/** Pre-formatted duration label, e.g. "00:08:17" (host formats it). */
|
|
@@ -38,6 +45,20 @@ export interface TimeTrackerData {
|
|
|
38
45
|
onTicketSearch?: (query: string) => void
|
|
39
46
|
ticketsLoading?: boolean
|
|
40
47
|
|
|
48
|
+
/**
|
|
49
|
+
* Customer (organization) selection. The panel renders a customer autocomplete
|
|
50
|
+
* beside the ticket field only when `onSelectedCustomerChange` is provided, so
|
|
51
|
+
* hosts without a customer concept are unaffected.
|
|
52
|
+
*/
|
|
53
|
+
customerOptions?: TimeTrackerCustomerOption[]
|
|
54
|
+
selectedCustomerId?: string | null
|
|
55
|
+
onSelectedCustomerChange?: (id: string | null) => void
|
|
56
|
+
/** Called as the user types in the customer field; host performs the search. */
|
|
57
|
+
onCustomerSearch?: (query: string) => void
|
|
58
|
+
customersLoading?: boolean
|
|
59
|
+
/** Lock the customer field (e.g. it was derived from the selected ticket). */
|
|
60
|
+
customerLocked?: boolean
|
|
61
|
+
|
|
41
62
|
notes: string
|
|
42
63
|
onNotesChange: (value: string) => void
|
|
43
64
|
|
|
@@ -199,7 +199,10 @@ export function getPlatformIconComponent(platformName: string, className: string
|
|
|
199
199
|
case 'openframe':
|
|
200
200
|
return <OpenFrameLogo className={className} />;
|
|
201
201
|
case 'openmsp':
|
|
202
|
-
|
|
202
|
+
// `OpenmspLogo` ignores `color`; it uses the three bubble props. On a dark
|
|
203
|
+
// surface the default black front-bubble vanishes — use the canonical dark
|
|
204
|
+
// treatment (matches getPlatformIcon above + every hub call-site).
|
|
205
|
+
return <OpenmspLogo className={className} frontBubbleColor="#f1f1f1" innerFrontBubbleColor="#000000" backBubbleColor="#FFC008" />;
|
|
203
206
|
case 'flamingo':
|
|
204
207
|
case 'flamingo-teaser':
|
|
205
208
|
return <FlamingoLogo className={`${className} text-white`} />;
|