@burdenoff/microfe-coolandlovely 2026.706.3 → 2026.710.2
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/coolandlovely/CoolAndLovelyRoot.d.ts +5 -0
- package/dist/coolandlovely/CoolAndLovelyRoot.d.ts.map +1 -0
- package/dist/coolandlovely/CoolAndLovelyRoutes.d.ts +4 -0
- package/dist/coolandlovely/CoolAndLovelyRoutes.d.ts.map +1 -0
- package/dist/coolandlovely/components/ActorName.d.ts +14 -0
- package/dist/coolandlovely/components/ActorName.d.ts.map +1 -0
- package/dist/coolandlovely/components/AddToLookbookButton.d.ts +10 -0
- package/dist/coolandlovely/components/AddToLookbookButton.d.ts.map +1 -0
- package/dist/coolandlovely/components/BrandCover.d.ts +17 -0
- package/dist/coolandlovely/components/BrandCover.d.ts.map +1 -0
- package/dist/coolandlovely/components/BrandCreatorAvatars.d.ts +14 -0
- package/dist/coolandlovely/components/BrandCreatorAvatars.d.ts.map +1 -0
- package/dist/coolandlovely/components/ColourSwatchRow.d.ts +11 -0
- package/dist/coolandlovely/components/ColourSwatchRow.d.ts.map +1 -0
- package/dist/coolandlovely/components/Comments.d.ts +14 -0
- package/dist/coolandlovely/components/Comments.d.ts.map +1 -0
- package/dist/coolandlovely/components/EmptyState.d.ts +14 -0
- package/dist/coolandlovely/components/EmptyState.d.ts.map +1 -0
- package/dist/coolandlovely/components/Field.d.ts +68 -0
- package/dist/coolandlovely/components/Field.d.ts.map +1 -0
- package/dist/coolandlovely/components/FileImage.d.ts +10 -0
- package/dist/coolandlovely/components/FileImage.d.ts.map +1 -0
- package/dist/coolandlovely/components/FollowButton.d.ts +11 -0
- package/dist/coolandlovely/components/FollowButton.d.ts.map +1 -0
- package/dist/coolandlovely/components/ImageUploadField.d.ts +21 -0
- package/dist/coolandlovely/components/ImageUploadField.d.ts.map +1 -0
- package/dist/coolandlovely/components/LookCard.d.ts +17 -0
- package/dist/coolandlovely/components/LookCard.d.ts.map +1 -0
- package/dist/coolandlovely/components/MetricsCard.d.ts +16 -0
- package/dist/coolandlovely/components/MetricsCard.d.ts.map +1 -0
- package/dist/coolandlovely/components/PageLayout.d.ts +17 -0
- package/dist/coolandlovely/components/PageLayout.d.ts.map +1 -0
- package/dist/coolandlovely/components/ShopItemCard.d.ts +15 -0
- package/dist/coolandlovely/components/ShopItemCard.d.ts.map +1 -0
- package/dist/coolandlovely/components/StateViews.d.ts +16 -0
- package/dist/coolandlovely/components/StateViews.d.ts.map +1 -0
- package/dist/coolandlovely/components/StatusBadge.d.ts +9 -0
- package/dist/coolandlovely/components/StatusBadge.d.ts.map +1 -0
- package/dist/coolandlovely/components/StepTracker.d.ts +12 -0
- package/dist/coolandlovely/components/StepTracker.d.ts.map +1 -0
- package/dist/coolandlovely/components/TagList.d.ts +12 -0
- package/dist/coolandlovely/components/TagList.d.ts.map +1 -0
- package/dist/coolandlovely/components/Thumbnail.d.ts +23 -0
- package/dist/coolandlovely/components/Thumbnail.d.ts.map +1 -0
- package/dist/coolandlovely/components/VisibilityChip.d.ts +10 -0
- package/dist/coolandlovely/components/VisibilityChip.d.ts.map +1 -0
- package/dist/coolandlovely/components/index.d.ts +26 -0
- package/dist/coolandlovely/components/index.d.ts.map +1 -0
- package/dist/coolandlovely/context/CoolAndLovelyContext.d.ts +16 -0
- package/dist/coolandlovely/context/CoolAndLovelyContext.d.ts.map +1 -0
- package/dist/coolandlovely/context/index.d.ts +6 -0
- package/dist/coolandlovely/context/index.d.ts.map +1 -0
- package/dist/coolandlovely/hooks/index.d.ts +11 -0
- package/dist/coolandlovely/hooks/index.d.ts.map +1 -0
- package/dist/coolandlovely/hooks/useComments.d.ts +37 -0
- package/dist/coolandlovely/hooks/useComments.d.ts.map +1 -0
- package/dist/coolandlovely/hooks/useCoolAndLovelyApi.d.ts +106 -0
- package/dist/coolandlovely/hooks/useCoolAndLovelyApi.d.ts.map +1 -0
- package/dist/coolandlovely/hooks/useFiles.d.ts +62 -0
- package/dist/coolandlovely/hooks/useFiles.d.ts.map +1 -0
- package/dist/coolandlovely/index.d.ts +11 -0
- package/dist/coolandlovely/index.d.ts.map +1 -0
- package/dist/coolandlovely/pages/HomePage.d.ts +10 -0
- package/dist/coolandlovely/pages/HomePage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/brands/BrandDetailPage.d.ts +9 -0
- package/dist/coolandlovely/pages/brands/BrandDetailPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/brands/BrandFormPage.d.ts +9 -0
- package/dist/coolandlovely/pages/brands/BrandFormPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/brands/BrandsListPage.d.ts +9 -0
- package/dist/coolandlovely/pages/brands/BrandsListPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/collaborations/CollaborationDetailPage.d.ts +9 -0
- package/dist/coolandlovely/pages/collaborations/CollaborationDetailPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/collaborations/CollaborationFormPage.d.ts +10 -0
- package/dist/coolandlovely/pages/collaborations/CollaborationFormPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/collaborations/CollaborationsListPage.d.ts +9 -0
- package/dist/coolandlovely/pages/collaborations/CollaborationsListPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/collections/CollectionDetailPage.d.ts +9 -0
- package/dist/coolandlovely/pages/collections/CollectionDetailPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/collections/CollectionFormPage.d.ts +9 -0
- package/dist/coolandlovely/pages/collections/CollectionFormPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/collections/CollectionsListPage.d.ts +8 -0
- package/dist/coolandlovely/pages/collections/CollectionsListPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/discover/DiscoverPage.d.ts +13 -0
- package/dist/coolandlovely/pages/discover/DiscoverPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/items/StyleItemDetailPage.d.ts +9 -0
- package/dist/coolandlovely/pages/items/StyleItemDetailPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/items/StyleItemFormPage.d.ts +10 -0
- package/dist/coolandlovely/pages/items/StyleItemFormPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/items/StyleItemsListPage.d.ts +9 -0
- package/dist/coolandlovely/pages/items/StyleItemsListPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/lookbooks/LookbookDetailPage.d.ts +12 -0
- package/dist/coolandlovely/pages/lookbooks/LookbookDetailPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/lookbooks/LookbooksListPage.d.ts +10 -0
- package/dist/coolandlovely/pages/lookbooks/LookbooksListPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/looks/LookDetailPage.d.ts +9 -0
- package/dist/coolandlovely/pages/looks/LookDetailPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/looks/LookFormPage.d.ts +10 -0
- package/dist/coolandlovely/pages/looks/LookFormPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/looks/LooksListPage.d.ts +9 -0
- package/dist/coolandlovely/pages/looks/LooksListPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/profile/StyleProfilePage.d.ts +12 -0
- package/dist/coolandlovely/pages/profile/StyleProfilePage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/trends/TrendsPage.d.ts +11 -0
- package/dist/coolandlovely/pages/trends/TrendsPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/wardrobe/WardrobeFormPage.d.ts +10 -0
- package/dist/coolandlovely/pages/wardrobe/WardrobeFormPage.d.ts.map +1 -0
- package/dist/coolandlovely/pages/wardrobe/WardrobeListPage.d.ts +12 -0
- package/dist/coolandlovely/pages/wardrobe/WardrobeListPage.d.ts.map +1 -0
- package/dist/coolandlovely/store/coolandlovelyStore.d.ts +56 -0
- package/dist/coolandlovely/store/coolandlovelyStore.d.ts.map +1 -0
- package/dist/coolandlovely/store/index.d.ts +6 -0
- package/dist/coolandlovely/store/index.d.ts.map +1 -0
- package/dist/coolandlovely/types/index.d.ts +451 -0
- package/dist/coolandlovely/types/index.d.ts.map +1 -0
- package/dist/coolandlovely/utils/cn.d.ts +4 -0
- package/dist/coolandlovely/utils/cn.d.ts.map +1 -0
- package/dist/coolandlovely/utils/formatters.d.ts +101 -0
- package/dist/coolandlovely/utils/formatters.d.ts.map +1 -0
- package/dist/coolandlovely/utils/icons.d.ts +6 -0
- package/dist/coolandlovely/utils/icons.d.ts.map +1 -0
- package/dist/coolandlovely/utils/index.d.ts +9 -0
- package/dist/coolandlovely/utils/index.d.ts.map +1 -0
- package/dist/coolandlovely/utils/navigation.d.ts +20 -0
- package/dist/coolandlovely/utils/navigation.d.ts.map +1 -0
- package/dist/generated/global-operations.d.ts +2 -0
- package/dist/generated/global-operations.d.ts.map +1 -0
- package/dist/generated/global-types.d.ts +23527 -0
- package/dist/generated/global-types.d.ts.map +1 -0
- package/dist/generated/wspace-operations.d.ts +2 -0
- package/dist/generated/wspace-operations.d.ts.map +1 -0
- package/dist/generated/wspace-types.d.ts +57851 -0
- package/dist/generated/wspace-types.d.ts.map +1 -0
- package/dist/index.d.ts +7 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +2 -1
- package/dist/services/createSandboxAssistantTransport.d.ts +44 -0
- package/dist/services/createSandboxAssistantTransport.d.ts.map +1 -0
- package/dist/services/createSandboxAssistantTransport.js +338 -0
- package/dist/services/createSandboxAssistantTransport.js.map +1 -0
- package/dist/utils/pageContext.d.ts +28 -0
- package/dist/utils/pageContext.d.ts.map +1 -0
- package/dist/utils/pageContext.js +51 -0
- package/dist/utils/pageContext.js.map +1 -0
- package/package.json +5 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"coolandlovelyStore.d.ts","sourceRoot":"","sources":["../../../src/coolandlovely/store/coolandlovelyStore.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAKH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAC;AAEzC,UAAU,kBAAkB;IAE1B,QAAQ,EAAE,QAAQ,CAAC;IACnB,aAAa,EAAE,MAAM,CAAC;IACtB,gBAAgB,EAAE,OAAO,CAAC;IAG1B,WAAW,EAAE,MAAM,CAAC;IACpB,cAAc,EAAE,MAAM,CAAC;IAGvB,WAAW,EAAE,CAAC,IAAI,EAAE,QAAQ,KAAK,IAAI,CAAC;IACtC,gBAAgB,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IAC5C,cAAc,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC,iBAAiB,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;IAC9C,aAAa,EAAE,MAAM,IAAI,CAAC;IAC1B,KAAK,EAAE,MAAM,IAAI,CAAC;CACnB;AAUD,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAyBjC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/coolandlovely/store/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,qBAAqB,EAAE,MAAM,sBAAsB,CAAC"}
|
|
@@ -0,0 +1,451 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
|
|
3
|
+
/** Navigation item for shell integration */
|
|
4
|
+
export interface NavItem {
|
|
5
|
+
id: string;
|
|
6
|
+
label: string;
|
|
7
|
+
path: string;
|
|
8
|
+
icon?: ReactNode;
|
|
9
|
+
badge?: number;
|
|
10
|
+
order?: number;
|
|
11
|
+
group?: string;
|
|
12
|
+
visible?: boolean;
|
|
13
|
+
/** When true, path is external (different microfe or full URL) */
|
|
14
|
+
external?: boolean;
|
|
15
|
+
children?: NavItem[];
|
|
16
|
+
}
|
|
17
|
+
/** Footer item for shell integration */
|
|
18
|
+
export interface FooterItem {
|
|
19
|
+
id: string;
|
|
20
|
+
label: string;
|
|
21
|
+
icon?: string;
|
|
22
|
+
onClick?: () => void;
|
|
23
|
+
type?: 'status' | 'action' | 'info';
|
|
24
|
+
order?: number;
|
|
25
|
+
badge?: string;
|
|
26
|
+
section?: 'left' | 'center' | 'right';
|
|
27
|
+
visible?: boolean;
|
|
28
|
+
}
|
|
29
|
+
/** Base microfrontend root props (extension point). */
|
|
30
|
+
export type MicrofrontendRootProps = Record<never, never>;
|
|
31
|
+
/** Current user information supplied by the host shell. */
|
|
32
|
+
export interface CoolAndLovelyUser {
|
|
33
|
+
id: string;
|
|
34
|
+
email: string;
|
|
35
|
+
name?: string;
|
|
36
|
+
firstName?: string;
|
|
37
|
+
lastName?: string;
|
|
38
|
+
avatar?: string;
|
|
39
|
+
phone?: string;
|
|
40
|
+
profilePicture?: string;
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* Props for the CoolAndLovelyRoot component.
|
|
44
|
+
*
|
|
45
|
+
* IMPORTANT: this is the host-shell contract — keep prop names/shape stable.
|
|
46
|
+
*/
|
|
47
|
+
export interface CoolAndLovelyRootProps extends MicrofrontendRootProps {
|
|
48
|
+
/** Base path for the coolandlovely microfrontend */
|
|
49
|
+
basePath?: string;
|
|
50
|
+
/** Workspace ID for scoping operations */
|
|
51
|
+
workspaceId?: string;
|
|
52
|
+
/** Tenant ID for multi-tenant context */
|
|
53
|
+
tenantId?: string;
|
|
54
|
+
/** Organization ID (optional context) */
|
|
55
|
+
organizationId?: string;
|
|
56
|
+
/** Workspace API Gateway URL for GraphQL requests */
|
|
57
|
+
apiGatewayUrl?: string;
|
|
58
|
+
/** Authentication token for API requests */
|
|
59
|
+
authToken?: string;
|
|
60
|
+
/** Workspace token (auto-attached by graphqlFetch when omitted) */
|
|
61
|
+
workspaceToken?: string;
|
|
62
|
+
/** Navigation function provided by the shell */
|
|
63
|
+
navigate?: (path: string) => void;
|
|
64
|
+
/** Current user information */
|
|
65
|
+
currentUser?: CoolAndLovelyUser;
|
|
66
|
+
/** Optional function to register navigation items with the shell */
|
|
67
|
+
registerNavItems?: (items: NavItem | NavItem[]) => () => void;
|
|
68
|
+
/** Optional function to register footer items with the shell */
|
|
69
|
+
registerFooterItems?: (items: FooterItem | FooterItem[]) => () => void;
|
|
70
|
+
}
|
|
71
|
+
/** Cursor pagination input — mirrors `PaginationInput`. */
|
|
72
|
+
export interface PaginationInput {
|
|
73
|
+
cursor?: string | null;
|
|
74
|
+
limit?: number;
|
|
75
|
+
offset?: number;
|
|
76
|
+
}
|
|
77
|
+
/** Connection page info — mirrors `CooPageInfo`. */
|
|
78
|
+
export interface CooPageInfo {
|
|
79
|
+
cursor: string | null;
|
|
80
|
+
hasMore: boolean;
|
|
81
|
+
}
|
|
82
|
+
/** Federation file reference — only the id is resolvable here. */
|
|
83
|
+
export interface CooFileRef {
|
|
84
|
+
id: string;
|
|
85
|
+
}
|
|
86
|
+
export type CooBrandStatus = 'DRAFT' | 'PENDING_REVIEW' | 'PUBLISHED' | 'SUSPENDED' | 'ARCHIVED';
|
|
87
|
+
export type CooCollectionStatus = 'DRAFT' | 'SCHEDULED' | 'LIVE' | 'ENDED' | 'ARCHIVED';
|
|
88
|
+
export type CooSeason = 'SPRING' | 'SUMMER' | 'AUTUMN' | 'WINTER' | 'RESORT' | 'ALL_SEASON';
|
|
89
|
+
export type CooStyleCategory = 'TOPS' | 'BOTTOMS' | 'DRESSES' | 'OUTERWEAR' | 'FOOTWEAR' | 'BAGS' | 'ACCESSORIES' | 'JEWELLERY' | 'BEAUTY' | 'OTHER';
|
|
90
|
+
export type CooStyleItemStatus = 'DRAFT' | 'ACTIVE' | 'OUT_OF_STOCK' | 'RETIRED';
|
|
91
|
+
export type CooLookOccasion = 'EVERYDAY' | 'WORK' | 'EVENING' | 'WEDDING_GUEST' | 'VACATION' | 'PARTY' | 'ACTIVE' | 'OTHER';
|
|
92
|
+
export type CooVisibility = 'PUBLIC' | 'FOLLOWERS' | 'PRIVATE';
|
|
93
|
+
export type CooCollaborationStatus = 'PROPOSED' | 'ACCEPTED' | 'IN_PROGRESS' | 'PUBLISHED' | 'DECLINED' | 'CANCELLED';
|
|
94
|
+
export type CooCollaboratorRole = 'CREATOR' | 'BRAND' | 'STYLIST' | 'PHOTOGRAPHER';
|
|
95
|
+
export type CooWardrobeSource = 'OWNED' | 'WISHLIST' | 'PURCHASED_ON_PLATFORM' | 'GIFTED';
|
|
96
|
+
export interface CooBrand {
|
|
97
|
+
id: string;
|
|
98
|
+
workspaceId: string;
|
|
99
|
+
name: string;
|
|
100
|
+
handle: string;
|
|
101
|
+
tagline: string | null;
|
|
102
|
+
bio: string | null;
|
|
103
|
+
aesthetics: string[];
|
|
104
|
+
tags: string[];
|
|
105
|
+
websiteUrl: string | null;
|
|
106
|
+
isFeatured: boolean;
|
|
107
|
+
status: CooBrandStatus;
|
|
108
|
+
logo: CooFileRef | null;
|
|
109
|
+
cover: CooFileRef | null;
|
|
110
|
+
createdAt: string;
|
|
111
|
+
updatedAt: string;
|
|
112
|
+
/** Populated by the `cooBrand` detail query. */
|
|
113
|
+
collections?: CooCollection[];
|
|
114
|
+
/** Populated by the `cooBrand` detail query. */
|
|
115
|
+
items?: CooStyleItem[];
|
|
116
|
+
}
|
|
117
|
+
export interface CooBrandConnection {
|
|
118
|
+
items: CooBrand[];
|
|
119
|
+
pageInfo: CooPageInfo;
|
|
120
|
+
}
|
|
121
|
+
export interface CooCollection {
|
|
122
|
+
id: string;
|
|
123
|
+
workspaceId: string;
|
|
124
|
+
brandId: string;
|
|
125
|
+
name: string;
|
|
126
|
+
description: string | null;
|
|
127
|
+
season: CooSeason;
|
|
128
|
+
status: CooCollectionStatus;
|
|
129
|
+
tags: string[];
|
|
130
|
+
cover: CooFileRef | null;
|
|
131
|
+
publishAt: string | null;
|
|
132
|
+
endAt: string | null;
|
|
133
|
+
createdAt: string;
|
|
134
|
+
updatedAt: string;
|
|
135
|
+
brand?: Pick<CooBrand, 'id' | 'name' | 'handle'> | null;
|
|
136
|
+
/** Populated by the `cooCollection` detail query. */
|
|
137
|
+
items?: CooStyleItem[];
|
|
138
|
+
}
|
|
139
|
+
export interface CooStyleItem {
|
|
140
|
+
id: string;
|
|
141
|
+
workspaceId: string;
|
|
142
|
+
brandId: string;
|
|
143
|
+
collectionId: string | null;
|
|
144
|
+
name: string;
|
|
145
|
+
description: string | null;
|
|
146
|
+
category: CooStyleCategory;
|
|
147
|
+
status: CooStyleItemStatus;
|
|
148
|
+
sku: string | null;
|
|
149
|
+
price: number;
|
|
150
|
+
currency: string;
|
|
151
|
+
colours: string[];
|
|
152
|
+
sizes: string[];
|
|
153
|
+
materials: string[];
|
|
154
|
+
tags: string[];
|
|
155
|
+
image: CooFileRef | null;
|
|
156
|
+
createdAt: string;
|
|
157
|
+
updatedAt: string;
|
|
158
|
+
brand?: Pick<CooBrand, 'id' | 'name' | 'handle'> | null;
|
|
159
|
+
collection?: Pick<CooCollection, 'id' | 'name'> | null;
|
|
160
|
+
}
|
|
161
|
+
export interface CooStyleItemConnection {
|
|
162
|
+
items: CooStyleItem[];
|
|
163
|
+
pageInfo: CooPageInfo;
|
|
164
|
+
}
|
|
165
|
+
export interface CooLookItem {
|
|
166
|
+
id: string;
|
|
167
|
+
workspaceId: string;
|
|
168
|
+
lookId: string;
|
|
169
|
+
styleItemId: string;
|
|
170
|
+
position: number;
|
|
171
|
+
styling: string | null;
|
|
172
|
+
createdAt: string;
|
|
173
|
+
updatedAt: string;
|
|
174
|
+
styleItem?: Pick<CooStyleItem, 'id' | 'name' | 'category' | 'price' | 'currency' | 'brand' | 'image'> | null;
|
|
175
|
+
}
|
|
176
|
+
export interface CooLook {
|
|
177
|
+
id: string;
|
|
178
|
+
workspaceId: string;
|
|
179
|
+
authorId: string;
|
|
180
|
+
title: string;
|
|
181
|
+
caption: string | null;
|
|
182
|
+
occasion: CooLookOccasion;
|
|
183
|
+
visibility: CooVisibility;
|
|
184
|
+
isFeatured: boolean;
|
|
185
|
+
likeCount: number;
|
|
186
|
+
saveCount: number;
|
|
187
|
+
collaborationId: string | null;
|
|
188
|
+
image: CooFileRef | null;
|
|
189
|
+
tags: string[];
|
|
190
|
+
publishedAt: string | null;
|
|
191
|
+
createdAt: string;
|
|
192
|
+
updatedAt: string;
|
|
193
|
+
items?: CooLookItem[];
|
|
194
|
+
}
|
|
195
|
+
export interface CooLookConnection {
|
|
196
|
+
items: CooLook[];
|
|
197
|
+
pageInfo: CooPageInfo;
|
|
198
|
+
}
|
|
199
|
+
export interface CooCollaboration {
|
|
200
|
+
id: string;
|
|
201
|
+
workspaceId: string;
|
|
202
|
+
brandId: string;
|
|
203
|
+
creatorId: string;
|
|
204
|
+
collectionId: string | null;
|
|
205
|
+
title: string;
|
|
206
|
+
brief: string | null;
|
|
207
|
+
role: CooCollaboratorRole;
|
|
208
|
+
status: CooCollaborationStatus;
|
|
209
|
+
compensation: number;
|
|
210
|
+
currency: string;
|
|
211
|
+
tags: string[];
|
|
212
|
+
startDate: string | null;
|
|
213
|
+
endDate: string | null;
|
|
214
|
+
publishedAt: string | null;
|
|
215
|
+
createdAt: string;
|
|
216
|
+
updatedAt: string;
|
|
217
|
+
brand?: Pick<CooBrand, 'id' | 'name' | 'handle' | 'logo'> | null;
|
|
218
|
+
/** Populated by the `cooCollaboration` detail query. */
|
|
219
|
+
looks?: CooLook[];
|
|
220
|
+
}
|
|
221
|
+
export interface CooStyleProfile {
|
|
222
|
+
id: string;
|
|
223
|
+
workspaceId: string;
|
|
224
|
+
ownerId: string;
|
|
225
|
+
displayName: string | null;
|
|
226
|
+
bio: string | null;
|
|
227
|
+
visibility: CooVisibility;
|
|
228
|
+
stylePreferences: string[];
|
|
229
|
+
palette: string[];
|
|
230
|
+
favouriteBrands: string[];
|
|
231
|
+
sizes: Record<string, unknown> | null;
|
|
232
|
+
createdAt: string;
|
|
233
|
+
updatedAt: string;
|
|
234
|
+
/** Follow graph (resolved on the CooStyleProfile type). */
|
|
235
|
+
isFollowedByMe?: boolean;
|
|
236
|
+
followerCount?: number;
|
|
237
|
+
followingCount?: number;
|
|
238
|
+
}
|
|
239
|
+
export interface CooWardrobeItem {
|
|
240
|
+
id: string;
|
|
241
|
+
workspaceId: string;
|
|
242
|
+
profileId: string;
|
|
243
|
+
name: string;
|
|
244
|
+
category: CooStyleCategory;
|
|
245
|
+
source: CooWardrobeSource;
|
|
246
|
+
brandName: string | null;
|
|
247
|
+
colour: string | null;
|
|
248
|
+
size: string | null;
|
|
249
|
+
notes: string | null;
|
|
250
|
+
styleItemId: string | null;
|
|
251
|
+
timesWorn: number;
|
|
252
|
+
lastWornAt: string | null;
|
|
253
|
+
tags: string[];
|
|
254
|
+
image: CooFileRef | null;
|
|
255
|
+
createdAt: string;
|
|
256
|
+
updatedAt: string;
|
|
257
|
+
}
|
|
258
|
+
export interface CooLookbookEntry {
|
|
259
|
+
id: string;
|
|
260
|
+
workspaceId: string;
|
|
261
|
+
lookbookId: string;
|
|
262
|
+
lookId: string | null;
|
|
263
|
+
styleItemId: string | null;
|
|
264
|
+
note: string | null;
|
|
265
|
+
position: number;
|
|
266
|
+
createdAt: string;
|
|
267
|
+
updatedAt: string;
|
|
268
|
+
}
|
|
269
|
+
export interface CooLookbook {
|
|
270
|
+
id: string;
|
|
271
|
+
workspaceId: string;
|
|
272
|
+
ownerId: string;
|
|
273
|
+
profileId: string;
|
|
274
|
+
name: string;
|
|
275
|
+
description: string | null;
|
|
276
|
+
visibility: CooVisibility;
|
|
277
|
+
tags: string[];
|
|
278
|
+
cover: CooFileRef | null;
|
|
279
|
+
createdAt: string;
|
|
280
|
+
updatedAt: string;
|
|
281
|
+
entries?: CooLookbookEntry[];
|
|
282
|
+
}
|
|
283
|
+
export interface CooCreateBrandInput {
|
|
284
|
+
name: string;
|
|
285
|
+
handle: string;
|
|
286
|
+
tagline?: string;
|
|
287
|
+
bio?: string;
|
|
288
|
+
aesthetics?: string[];
|
|
289
|
+
tags?: string[];
|
|
290
|
+
websiteUrl?: string;
|
|
291
|
+
logoFileId?: string;
|
|
292
|
+
coverFileId?: string;
|
|
293
|
+
}
|
|
294
|
+
export interface CooUpdateBrandInput {
|
|
295
|
+
name?: string;
|
|
296
|
+
tagline?: string;
|
|
297
|
+
bio?: string;
|
|
298
|
+
aesthetics?: string[];
|
|
299
|
+
tags?: string[];
|
|
300
|
+
websiteUrl?: string;
|
|
301
|
+
logoFileId?: string;
|
|
302
|
+
coverFileId?: string;
|
|
303
|
+
isFeatured?: boolean;
|
|
304
|
+
}
|
|
305
|
+
export interface CooCreateCollectionInput {
|
|
306
|
+
brandId: string;
|
|
307
|
+
name: string;
|
|
308
|
+
description?: string;
|
|
309
|
+
season?: CooSeason;
|
|
310
|
+
tags?: string[];
|
|
311
|
+
coverFileId?: string;
|
|
312
|
+
publishAt?: string;
|
|
313
|
+
endAt?: string;
|
|
314
|
+
}
|
|
315
|
+
export interface CooUpdateCollectionInput {
|
|
316
|
+
name?: string;
|
|
317
|
+
description?: string;
|
|
318
|
+
season?: CooSeason;
|
|
319
|
+
tags?: string[];
|
|
320
|
+
coverFileId?: string;
|
|
321
|
+
publishAt?: string;
|
|
322
|
+
endAt?: string;
|
|
323
|
+
}
|
|
324
|
+
export interface CooCreateStyleItemInput {
|
|
325
|
+
brandId: string;
|
|
326
|
+
name: string;
|
|
327
|
+
description?: string;
|
|
328
|
+
category?: CooStyleCategory;
|
|
329
|
+
collectionId?: string;
|
|
330
|
+
sku?: string;
|
|
331
|
+
price?: number;
|
|
332
|
+
currency?: string;
|
|
333
|
+
colours?: string[];
|
|
334
|
+
sizes?: string[];
|
|
335
|
+
materials?: string[];
|
|
336
|
+
tags?: string[];
|
|
337
|
+
imageFileId?: string;
|
|
338
|
+
}
|
|
339
|
+
export interface CooUpdateStyleItemInput {
|
|
340
|
+
name?: string;
|
|
341
|
+
description?: string;
|
|
342
|
+
category?: CooStyleCategory;
|
|
343
|
+
collectionId?: string;
|
|
344
|
+
sku?: string;
|
|
345
|
+
price?: number;
|
|
346
|
+
currency?: string;
|
|
347
|
+
colours?: string[];
|
|
348
|
+
sizes?: string[];
|
|
349
|
+
materials?: string[];
|
|
350
|
+
tags?: string[];
|
|
351
|
+
imageFileId?: string;
|
|
352
|
+
}
|
|
353
|
+
export interface CooLookItemInput {
|
|
354
|
+
styleItemId: string;
|
|
355
|
+
position?: number;
|
|
356
|
+
styling?: string;
|
|
357
|
+
}
|
|
358
|
+
export interface CooCreateLookInput {
|
|
359
|
+
title: string;
|
|
360
|
+
caption?: string;
|
|
361
|
+
occasion?: CooLookOccasion;
|
|
362
|
+
visibility?: CooVisibility;
|
|
363
|
+
collaborationId?: string;
|
|
364
|
+
imageFileId?: string;
|
|
365
|
+
tags?: string[];
|
|
366
|
+
items?: CooLookItemInput[];
|
|
367
|
+
}
|
|
368
|
+
export interface CooUpdateLookInput {
|
|
369
|
+
title?: string;
|
|
370
|
+
caption?: string;
|
|
371
|
+
occasion?: CooLookOccasion;
|
|
372
|
+
visibility?: CooVisibility;
|
|
373
|
+
tags?: string[];
|
|
374
|
+
imageFileId?: string;
|
|
375
|
+
/** Added this release — feature/unfeature a look. */
|
|
376
|
+
isFeatured?: boolean;
|
|
377
|
+
}
|
|
378
|
+
/** Input for adding an entry to a lookbook (mirrors CooAddLookbookEntryInput). */
|
|
379
|
+
export interface CooAddLookbookEntryInput {
|
|
380
|
+
lookbookId: string;
|
|
381
|
+
lookId?: string;
|
|
382
|
+
styleItemId?: string;
|
|
383
|
+
note?: string;
|
|
384
|
+
position?: number;
|
|
385
|
+
}
|
|
386
|
+
export interface CooCreateCollaborationInput {
|
|
387
|
+
brandId: string;
|
|
388
|
+
creatorId: string;
|
|
389
|
+
title: string;
|
|
390
|
+
brief?: string;
|
|
391
|
+
collectionId?: string;
|
|
392
|
+
role?: CooCollaboratorRole;
|
|
393
|
+
compensation?: number;
|
|
394
|
+
currency?: string;
|
|
395
|
+
tags?: string[];
|
|
396
|
+
startDate?: string;
|
|
397
|
+
endDate?: string;
|
|
398
|
+
}
|
|
399
|
+
export interface CooCreateWardrobeItemInput {
|
|
400
|
+
name: string;
|
|
401
|
+
category?: CooStyleCategory;
|
|
402
|
+
source?: CooWardrobeSource;
|
|
403
|
+
brandName?: string;
|
|
404
|
+
colour?: string;
|
|
405
|
+
size?: string;
|
|
406
|
+
notes?: string;
|
|
407
|
+
styleItemId?: string;
|
|
408
|
+
tags?: string[];
|
|
409
|
+
imageFileId?: string;
|
|
410
|
+
}
|
|
411
|
+
export interface CooUpdateWardrobeItemInput {
|
|
412
|
+
name?: string;
|
|
413
|
+
category?: CooStyleCategory;
|
|
414
|
+
source?: CooWardrobeSource;
|
|
415
|
+
brandName?: string;
|
|
416
|
+
colour?: string;
|
|
417
|
+
size?: string;
|
|
418
|
+
notes?: string;
|
|
419
|
+
tags?: string[];
|
|
420
|
+
imageFileId?: string;
|
|
421
|
+
}
|
|
422
|
+
export interface CooUpsertStyleProfileInput {
|
|
423
|
+
displayName?: string;
|
|
424
|
+
bio?: string;
|
|
425
|
+
visibility?: CooVisibility;
|
|
426
|
+
stylePreferences?: string[];
|
|
427
|
+
palette?: string[];
|
|
428
|
+
favouriteBrands?: string[];
|
|
429
|
+
sizes?: Record<string, unknown>;
|
|
430
|
+
}
|
|
431
|
+
export interface CooCreateLookbookInput {
|
|
432
|
+
name: string;
|
|
433
|
+
description?: string;
|
|
434
|
+
visibility?: CooVisibility;
|
|
435
|
+
tags?: string[];
|
|
436
|
+
coverFileId?: string;
|
|
437
|
+
}
|
|
438
|
+
export type ViewMode = 'grid' | 'list';
|
|
439
|
+
export type TrendDirection = 'up' | 'down' | 'neutral';
|
|
440
|
+
/** Overview dashboard rollup (derived client-side from list ops). */
|
|
441
|
+
export interface DashboardStats {
|
|
442
|
+
totalBrands: number;
|
|
443
|
+
publishedBrands: number;
|
|
444
|
+
totalStyleItems: number;
|
|
445
|
+
activeStyleItems: number;
|
|
446
|
+
totalLooks: number;
|
|
447
|
+
featuredLooks: number;
|
|
448
|
+
activeCollaborations: number;
|
|
449
|
+
wardrobeItems: number;
|
|
450
|
+
}
|
|
451
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1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AAE,MAAM,EAAE,CAAC;IAChB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAMD,MAAM,MAAM,QAAQ,GAAG,MAAM,GAAG,MAAM,CAAC;AAEvC,MAAM,MAAM,cAAc,GAAG,IAAI,GAAG,MAAM,GAAG,SAAS,CAAC;AAEvD,qEAAqE;AACrE,MAAM,WAAW,cAAc;IAC7B,WAAW,EAAE,MAAM,CAAC;IACpB,eAAe,EAAE,MAAM,CAAC;IACxB,eAAe,EAAE,MAAM,CAAC;IACxB,gBAAgB,EAAE,MAAM,CAAC;IACzB,UAAU,EAAE,MAAM,CAAC;IACnB,aAAa,EAAE,MAAM,CAAC;IACtB,oBAAoB,EAAE,MAAM,CAAC;IAC7B,aAAa,EAAE,MAAM,CAAC;CACvB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cn.d.ts","sourceRoot":"","sources":["../../../src/coolandlovely/utils/cn.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAQ,KAAK,UAAU,EAAE,MAAM,MAAM,CAAC;AAG7C,wBAAgB,EAAE,CAAC,GAAG,MAAM,EAAE,UAAU,EAAE,GAAG,MAAM,CAElD"}
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Formatting utilities for the CoolAndLovely microfrontend
|
|
3
|
+
* @module coolandlovely/utils/formatters
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* Format a number as currency. Defaults to USD but accepts any ISO currency
|
|
7
|
+
* code (CoolAndLovely items/collaborations carry a per-record `currency`).
|
|
8
|
+
*
|
|
9
|
+
* @param amount - The numeric amount to format
|
|
10
|
+
* @param currency - ISO 4217 currency code (defaults to "USD")
|
|
11
|
+
* @param options - Optional Intl.NumberFormat options to override defaults
|
|
12
|
+
* @returns Formatted currency string (e.g., "$1,200.00")
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* formatPrice(1200) // => "$1,200.00"
|
|
16
|
+
* formatPrice(1200, 'EUR') // => "€1,200.00"
|
|
17
|
+
* formatPrice(1200, 'INR', { minimumFractionDigits: 0 }) // => "₹1,200"
|
|
18
|
+
*/
|
|
19
|
+
export declare function formatPrice(amount: number, currency?: string, options?: Partial<Intl.NumberFormatOptions>): string;
|
|
20
|
+
/**
|
|
21
|
+
* Format a number as currency (legacy alias kept for the shared export
|
|
22
|
+
* surface). Defaults to USD; pass a currency code as the second arg.
|
|
23
|
+
*/
|
|
24
|
+
export declare function formatCurrency(amount: number, options?: Partial<Intl.NumberFormatOptions>): string;
|
|
25
|
+
/**
|
|
26
|
+
* Convert an UPPER_SNAKE_CASE enum value into a Title Case label.
|
|
27
|
+
*
|
|
28
|
+
* @example
|
|
29
|
+
* titleCase('PENDING_REVIEW') // => "Pending Review"
|
|
30
|
+
* titleCase('LIVE') // => "Live"
|
|
31
|
+
*/
|
|
32
|
+
export declare function titleCase(value: string): string;
|
|
33
|
+
/**
|
|
34
|
+
* Parse a comma-separated input into a trimmed, de-duplicated string array.
|
|
35
|
+
* Empty entries are dropped. Returns `[]` for blank input.
|
|
36
|
+
*
|
|
37
|
+
* @example
|
|
38
|
+
* parseCsv('minimal, Y2K , minimal') // => ['minimal', 'Y2K']
|
|
39
|
+
*/
|
|
40
|
+
export declare function parseCsv(input: string): string[];
|
|
41
|
+
/**
|
|
42
|
+
* Format a date string or Date object into a human-readable format
|
|
43
|
+
*
|
|
44
|
+
* @param date - ISO date string or Date object
|
|
45
|
+
* @param options - Optional Intl.DateTimeFormat options
|
|
46
|
+
* @returns Formatted date string (e.g., "15 Jan 2024, 4:00 PM")
|
|
47
|
+
*
|
|
48
|
+
* @example
|
|
49
|
+
* formatDate('2024-01-15T10:30:00Z')
|
|
50
|
+
* // => "15 Jan 2024, 4:00 PM" (in IST)
|
|
51
|
+
*/
|
|
52
|
+
export declare function formatDate(date: string | Date, options?: Partial<Intl.DateTimeFormatOptions>): string;
|
|
53
|
+
/**
|
|
54
|
+
* Format a date into a relative time string (e.g., "2 hours ago")
|
|
55
|
+
*
|
|
56
|
+
* @param date - ISO date string or Date object
|
|
57
|
+
* @returns Human-readable relative time string
|
|
58
|
+
*
|
|
59
|
+
* @example
|
|
60
|
+
* formatRelativeTime('2024-01-15T10:30:00Z') // => "3 days ago"
|
|
61
|
+
* formatRelativeTime(new Date()) // => "just now"
|
|
62
|
+
*/
|
|
63
|
+
export declare function formatRelativeTime(date: string | Date): string;
|
|
64
|
+
/**
|
|
65
|
+
* Format a number with Indian locale grouping (lakhs, crores)
|
|
66
|
+
*
|
|
67
|
+
* @param value - The number to format
|
|
68
|
+
* @param options - Optional Intl.NumberFormat options
|
|
69
|
+
* @returns Formatted number string (e.g., "12,345" or "1,24,500")
|
|
70
|
+
*
|
|
71
|
+
* @example
|
|
72
|
+
* formatNumber(1245) // => "1,245"
|
|
73
|
+
* formatNumber(124500) // => "1,24,500"
|
|
74
|
+
*/
|
|
75
|
+
export declare function formatNumber(value: number, options?: Partial<Intl.NumberFormatOptions>): string;
|
|
76
|
+
/**
|
|
77
|
+
* Format a distance value in kilometers
|
|
78
|
+
*
|
|
79
|
+
* @param km - Distance in kilometers
|
|
80
|
+
* @returns Formatted distance string
|
|
81
|
+
*
|
|
82
|
+
* @example
|
|
83
|
+
* formatDistance(0.5) // => "500 m"
|
|
84
|
+
* formatDistance(1.2) // => "1.2 km"
|
|
85
|
+
* formatDistance(15) // => "15 km"
|
|
86
|
+
*/
|
|
87
|
+
export declare function formatDistance(km: number): string;
|
|
88
|
+
/**
|
|
89
|
+
* Format a duration in minutes into a human-readable string
|
|
90
|
+
*
|
|
91
|
+
* @param minutes - Duration in minutes
|
|
92
|
+
* @returns Formatted duration string
|
|
93
|
+
*
|
|
94
|
+
* @example
|
|
95
|
+
* formatDuration(5) // => "5 min"
|
|
96
|
+
* formatDuration(90) // => "1h 30min"
|
|
97
|
+
* formatDuration(1440) // => "1 day"
|
|
98
|
+
* formatDuration(4320) // => "3 days"
|
|
99
|
+
*/
|
|
100
|
+
export declare function formatDuration(minutes: number): string;
|
|
101
|
+
//# sourceMappingURL=formatters.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"formatters.d.ts","sourceRoot":"","sources":["../../../src/coolandlovely/utils/formatters.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;;;;;;;;;;GAaG;AACH,wBAAgB,WAAW,CACzB,MAAM,EAAE,MAAM,EACd,QAAQ,SAAQ,EAChB,OAAO,CAAC,EAAE,OAAO,CAAC,IAAI,CAAC,mBAAmB,CAAC,GAC1C,MAAM,CAaR;AAED;;;GAGG;AACH,wBAAgB,cAAc,CAC5B,MAAM,EAAE,MAAM,EACd,OAAO,CAAC,EAAE,OAAO,CAAC,IAAI,CAAC,mBAAmB,CAAC,GAC1C,MAAM,CAER;AAED;;;;;;GAMG;AACH,wBAAgB,SAAS,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAK/C;AAED;;;;;;GAMG;AACH,wBAAgB,QAAQ,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,EAAE,CAWhD;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,UAAU,CACxB,IAAI,EAAE,MAAM,GAAG,IAAI,EACnB,OAAO,CAAC,EAAE,OAAO,CAAC,IAAI,CAAC,qBAAqB,CAAC,GAC5C,MAAM,CAWR;AAED;;;;;;;;;GASG;AACH,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,GAAG,MAAM,CAoB9D;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,IAAI,CAAC,mBAAmB,CAAC,GAAG,MAAM,CAE/F;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,cAAc,CAAC,EAAE,EAAE,MAAM,GAAG,MAAM,CAQjD;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,cAAc,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAqBtD"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { CooStyleCategory } from '../types';
|
|
3
|
+
|
|
4
|
+
export declare function categoryIcon(category: CooStyleCategory, size?: number): ReactNode;
|
|
5
|
+
export declare const STYLE_CATEGORIES: CooStyleCategory[];
|
|
6
|
+
//# sourceMappingURL=icons.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"icons.d.ts","sourceRoot":"","sources":["../../../src/coolandlovely/utils/icons.tsx"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAYvC,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAEjD,wBAAgB,YAAY,CAAC,QAAQ,EAAE,gBAAgB,EAAE,IAAI,SAAK,GAAG,SAAS,CAyB7E;AAED,eAAO,MAAM,gBAAgB,EAAE,gBAAgB,EAW9C,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Utilities Index
|
|
3
|
+
* @module coolandlovely/utils
|
|
4
|
+
*/
|
|
5
|
+
export { cn } from './cn';
|
|
6
|
+
export { joinPath } from './navigation';
|
|
7
|
+
export { formatPrice, formatCurrency, formatDate, formatRelativeTime, formatNumber, formatDistance, formatDuration, titleCase, parseCsv, } from './formatters';
|
|
8
|
+
export { categoryIcon, STYLE_CATEGORIES } from './icons';
|
|
9
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/coolandlovely/utils/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,EAAE,EAAE,MAAM,MAAM,CAAC;AAC1B,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AACxC,OAAO,EACL,WAAW,EACX,cAAc,EACd,UAAU,EACV,kBAAkB,EAClB,YAAY,EACZ,cAAc,EACd,cAAc,EACd,SAAS,EACT,QAAQ,GACT,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Navigation utilities for the CoolAndLovely microfrontend
|
|
3
|
+
* @module coolandlovely/utils
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* Join basePath with a relative path, correctly handling slashes
|
|
7
|
+
*
|
|
8
|
+
* @param basePath - The base path (e.g., '/' or '/coolandlovely')
|
|
9
|
+
* @param relativePath - The relative path (e.g., 'carts/new' or '/carts/new')
|
|
10
|
+
* @returns The joined path (e.g., '/coolandlovely/carts/new')
|
|
11
|
+
*
|
|
12
|
+
* @example
|
|
13
|
+
* joinPath('/', 'carts/new') // => '/carts/new'
|
|
14
|
+
* joinPath('/', '/carts/new') // => '/carts/new'
|
|
15
|
+
* joinPath('/coolandlovely', 'orders') // => '/coolandlovely/orders'
|
|
16
|
+
* joinPath('/coolandlovely/', 'orders') // => '/coolandlovely/orders'
|
|
17
|
+
* joinPath('/coolandlovely', '') // => '/coolandlovely'
|
|
18
|
+
*/
|
|
19
|
+
export declare function joinPath(basePath: string, relativePath: string): string;
|
|
20
|
+
//# sourceMappingURL=navigation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"navigation.d.ts","sourceRoot":"","sources":["../../../src/coolandlovely/utils/navigation.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;;;;;;;;;;GAaG;AACH,wBAAgB,QAAQ,CAAC,QAAQ,EAAE,MAAM,EAAE,YAAY,EAAE,MAAM,GAAG,MAAM,CAcvE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"global-operations.d.ts","sourceRoot":"","sources":["../../src/generated/global-operations.ts"],"names":[],"mappings":""}
|