@pelatform/starter.shared 0.2.3 → 0.2.4
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 +194 -5
- package/dist/index.js +127 -9
- package/package.json +2 -6
- package/dist/extend.d.ts +0 -107
- package/dist/extend.js +0 -117
- package/dist/view-B1v2TRLo.d.ts +0 -96
package/dist/index.d.ts
CHANGED
|
@@ -1,14 +1,13 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import * as react from 'react';
|
|
3
|
-
import { ReactNode, CSSProperties, ComponentProps, PropsWithChildren } from 'react';
|
|
3
|
+
import { ReactNode, CSSProperties, ComponentProps, PropsWithChildren, ComponentType } from 'react';
|
|
4
4
|
import { MenuItem } from 'pelatform-ui';
|
|
5
5
|
import { NavItem, LanguageSwitcherProps } from 'pelatform-ui/components';
|
|
6
6
|
export { Logo as LogoDefault } from 'pelatform-ui/components';
|
|
7
7
|
import { Config } from '@pelatform/starter.config';
|
|
8
8
|
import { AuthQueryOptions } from '@pelatform/starter.hook';
|
|
9
|
-
import { AnyAuthClient, ApiKey } from '@pelatform/starter.utils';
|
|
10
|
-
import { Toaster, Button, Input } from 'pelatform-ui/default';
|
|
11
|
-
import { b as CardComponentProps, c as DialogComponentProps, C as CardClassNames, a as AvatarProps, d as ViewProps } from './view-B1v2TRLo.js';
|
|
9
|
+
import { AnyAuthClient, User, Workspace, ApiKey } from '@pelatform/starter.utils';
|
|
10
|
+
import { Toaster, Avatar, buttonVariants, Dialog, Card, Button, Input } from 'pelatform-ui/default';
|
|
12
11
|
import { LucideIcon } from 'lucide-react';
|
|
13
12
|
|
|
14
13
|
declare function AuthLayout({ children, logo, disableFooter, signInHint, signInHref, }: {
|
|
@@ -139,6 +138,79 @@ interface SharedProvidersProps {
|
|
|
139
138
|
}
|
|
140
139
|
declare function SharedProviders({ children, locale, messages, timeZone, sonnerPosition, }: SharedProvidersProps): react_jsx_runtime.JSX.Element;
|
|
141
140
|
|
|
141
|
+
type AvatarClassNames = {
|
|
142
|
+
base?: string;
|
|
143
|
+
fallback?: string;
|
|
144
|
+
fallbackIcon?: string;
|
|
145
|
+
image?: string;
|
|
146
|
+
skeleton?: string;
|
|
147
|
+
};
|
|
148
|
+
interface AvatarProps extends ComponentProps<typeof Avatar> {
|
|
149
|
+
className?: string;
|
|
150
|
+
classNames?: AvatarClassNames;
|
|
151
|
+
image?: string;
|
|
152
|
+
isPending?: boolean;
|
|
153
|
+
size?: NonNullable<Parameters<typeof buttonVariants>[0]>["size"] | null | undefined;
|
|
154
|
+
user?: Partial<User> | null;
|
|
155
|
+
workspace?: Partial<Workspace> | null;
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
type DialogClassNames = {
|
|
159
|
+
content?: string;
|
|
160
|
+
header?: string;
|
|
161
|
+
footer?: string;
|
|
162
|
+
};
|
|
163
|
+
interface DialogComponentProps extends ComponentProps<typeof Dialog> {
|
|
164
|
+
className?: string;
|
|
165
|
+
children?: ReactNode;
|
|
166
|
+
classNames?: CardClassNames;
|
|
167
|
+
title?: string;
|
|
168
|
+
description?: string;
|
|
169
|
+
disableFooter?: boolean;
|
|
170
|
+
cancelButton?: boolean;
|
|
171
|
+
cancelButtonDisabled?: boolean;
|
|
172
|
+
button?: ReactNode;
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
type CardClassNames = {
|
|
176
|
+
base?: string;
|
|
177
|
+
cell?: string;
|
|
178
|
+
content?: string;
|
|
179
|
+
header?: string;
|
|
180
|
+
footer?: string;
|
|
181
|
+
grid?: string;
|
|
182
|
+
skeleton?: string;
|
|
183
|
+
title?: string;
|
|
184
|
+
description?: string;
|
|
185
|
+
instructions?: string;
|
|
186
|
+
error?: string;
|
|
187
|
+
label?: string;
|
|
188
|
+
input?: string;
|
|
189
|
+
checkbox?: string;
|
|
190
|
+
icon?: string;
|
|
191
|
+
button?: string;
|
|
192
|
+
primaryButton?: string;
|
|
193
|
+
secondaryButton?: string;
|
|
194
|
+
outlineButton?: string;
|
|
195
|
+
destructiveButton?: string;
|
|
196
|
+
avatar?: AvatarClassNames;
|
|
197
|
+
dialog?: DialogClassNames;
|
|
198
|
+
};
|
|
199
|
+
interface CardComponentProps extends Omit<ComponentProps<typeof Card>, "title" | "variant"> {
|
|
200
|
+
className?: string;
|
|
201
|
+
children?: ReactNode;
|
|
202
|
+
classNames?: CardClassNames;
|
|
203
|
+
title?: ReactNode;
|
|
204
|
+
description?: ReactNode;
|
|
205
|
+
instructions?: ReactNode;
|
|
206
|
+
actionLabel?: ReactNode;
|
|
207
|
+
action?: () => Promise<unknown> | unknown;
|
|
208
|
+
disabled?: boolean;
|
|
209
|
+
isDestructive?: boolean;
|
|
210
|
+
isPending?: boolean;
|
|
211
|
+
isSubmitting?: boolean;
|
|
212
|
+
}
|
|
213
|
+
|
|
142
214
|
declare function CardComponent({ children, className, classNames, title, description, instructions, actionLabel, action, disabled, isDestructive, isPending, isSubmitting, ...props }: CardComponentProps): react_jsx_runtime.JSX.Element;
|
|
143
215
|
declare function CardHeaderComponent({ className, classNames, title, description, isPending, }: CardComponentProps): react_jsx_runtime.JSX.Element;
|
|
144
216
|
declare function CardFooterComponent({ className, classNames, instructions, actionLabel, action, disabled, isDestructive, isPending, isSubmitting, }: CardComponentProps): react_jsx_runtime.JSX.Element;
|
|
@@ -199,10 +271,127 @@ declare function UserMenu({ hiddenSwitcher }: {
|
|
|
199
271
|
hiddenSwitcher?: boolean;
|
|
200
272
|
}): react_jsx_runtime.JSX.Element;
|
|
201
273
|
|
|
274
|
+
type ViewClassNames = {
|
|
275
|
+
base?: string;
|
|
276
|
+
content?: string;
|
|
277
|
+
title?: string;
|
|
278
|
+
subtitle?: string;
|
|
279
|
+
skeleton?: string;
|
|
280
|
+
icon?: string;
|
|
281
|
+
avatar?: AvatarClassNames;
|
|
282
|
+
};
|
|
283
|
+
interface ViewProps {
|
|
284
|
+
className?: string;
|
|
285
|
+
classNames?: ViewClassNames;
|
|
286
|
+
isPending?: boolean;
|
|
287
|
+
size?: NonNullable<Parameters<typeof buttonVariants>[0]>["size"] | null | undefined;
|
|
288
|
+
user?: Partial<User> | null;
|
|
289
|
+
workspace?: Partial<Workspace> | null;
|
|
290
|
+
}
|
|
291
|
+
|
|
202
292
|
declare function UserView({ className, classNames, isPending, size, user }: ViewProps): react_jsx_runtime.JSX.Element;
|
|
203
293
|
declare function ApiKeyView({ className, classNames, apiKey }: ViewProps & {
|
|
204
294
|
apiKey: ApiKey;
|
|
205
295
|
}): react_jsx_runtime.JSX.Element;
|
|
206
296
|
declare function WorkspaceView({ className, classNames, isPending, size, workspace }: ViewProps): react_jsx_runtime.JSX.Element;
|
|
207
297
|
|
|
208
|
-
|
|
298
|
+
declare const socialProviders: readonly [{
|
|
299
|
+
readonly provider: "apple";
|
|
300
|
+
readonly name: "Apple";
|
|
301
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
302
|
+
}, {
|
|
303
|
+
readonly provider: "discord";
|
|
304
|
+
readonly name: "Discord";
|
|
305
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
306
|
+
}, {
|
|
307
|
+
readonly provider: "dropbox";
|
|
308
|
+
readonly name: "Dropbox";
|
|
309
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
310
|
+
}, {
|
|
311
|
+
readonly provider: "facebook";
|
|
312
|
+
readonly name: "Facebook";
|
|
313
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
314
|
+
}, {
|
|
315
|
+
readonly provider: "github";
|
|
316
|
+
readonly name: "GitHub";
|
|
317
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
318
|
+
}, {
|
|
319
|
+
readonly provider: "gitlab";
|
|
320
|
+
readonly name: "GitLab";
|
|
321
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
322
|
+
}, {
|
|
323
|
+
readonly provider: "google";
|
|
324
|
+
readonly name: "Google";
|
|
325
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
326
|
+
}, {
|
|
327
|
+
readonly provider: "huggingface";
|
|
328
|
+
readonly name: "Hugging Face";
|
|
329
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
330
|
+
}, {
|
|
331
|
+
readonly provider: "kick";
|
|
332
|
+
readonly name: "Kick";
|
|
333
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
334
|
+
}, {
|
|
335
|
+
readonly provider: "linear";
|
|
336
|
+
readonly name: "Linear";
|
|
337
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
338
|
+
}, {
|
|
339
|
+
readonly provider: "linkedin";
|
|
340
|
+
readonly name: "LinkedIn";
|
|
341
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
342
|
+
}, {
|
|
343
|
+
readonly provider: "microsoft";
|
|
344
|
+
readonly name: "Microsoft";
|
|
345
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
346
|
+
}, {
|
|
347
|
+
readonly provider: "notion";
|
|
348
|
+
readonly name: "Notion";
|
|
349
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
350
|
+
}, {
|
|
351
|
+
readonly provider: "reddit";
|
|
352
|
+
readonly name: "Reddit";
|
|
353
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
354
|
+
}, {
|
|
355
|
+
readonly provider: "roblox";
|
|
356
|
+
readonly name: "Roblox";
|
|
357
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
358
|
+
}, {
|
|
359
|
+
readonly provider: "slack";
|
|
360
|
+
readonly name: "Slack";
|
|
361
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
362
|
+
}, {
|
|
363
|
+
readonly provider: "spotify";
|
|
364
|
+
readonly name: "Spotify";
|
|
365
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
366
|
+
}, {
|
|
367
|
+
readonly provider: "tiktok";
|
|
368
|
+
readonly name: "TikTok";
|
|
369
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
370
|
+
}, {
|
|
371
|
+
readonly provider: "twitch";
|
|
372
|
+
readonly name: "Twitch";
|
|
373
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
374
|
+
}, {
|
|
375
|
+
readonly provider: "vk";
|
|
376
|
+
readonly name: "VK";
|
|
377
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
378
|
+
}, {
|
|
379
|
+
readonly provider: "twitter";
|
|
380
|
+
readonly name: "X";
|
|
381
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
382
|
+
}, {
|
|
383
|
+
readonly provider: "zoom";
|
|
384
|
+
readonly name: "Zoom";
|
|
385
|
+
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
386
|
+
}];
|
|
387
|
+
|
|
388
|
+
type ProviderIcon = ComponentType<{
|
|
389
|
+
className?: string;
|
|
390
|
+
}>;
|
|
391
|
+
type Provider = {
|
|
392
|
+
provider: string;
|
|
393
|
+
name: string;
|
|
394
|
+
icon?: ProviderIcon;
|
|
395
|
+
};
|
|
396
|
+
|
|
397
|
+
export { ApiKeyView, AuthLayout, type AvatarClassNames, type AvatarProps, CardActionComponent, type CardClassNames, CardComponent, type CardComponentProps, CardFooterComponent, CardHeaderComponent, ConfigProvider, type ConfigProviderProps, type DialogClassNames, DialogComponent, type DialogComponentProps, DialogFooterComponent, DisplayIdCard, EmptyState, type EmptyStateProps, Header, HeaderLeft, HeaderRight, HeaderSidebarMobile, LanguageSwitcher, LayoutLoader, LayoutProvider, type LayoutProviderProps, LayoutWrapper, LogoWithHref, LogoWithName, OTPInputGroup, PasswordInput, type Provider, type ProviderIcon, SharedProviders, type SharedProvidersProps, Sidebar, SidebarContent, SidebarContentMenu, SidebarHeaderBack, SignedInHint, SiteFooter, SiteHeader, SiteHeaderSecondary, SkeletonInputComponent, SkeletonViewComponent, Toolbar, UserAvatar, UserMenu, UserView, type ViewClassNames, type ViewProps, WorkspaceLogo, WorkspaceView, socialProviders };
|
package/dist/index.js
CHANGED
|
@@ -239,7 +239,7 @@ import {
|
|
|
239
239
|
// src/components/view.tsx
|
|
240
240
|
import { KeyRoundIcon } from "lucide-react";
|
|
241
241
|
import { useLocale as useLocale2, useTranslations as useTranslations6 } from "next-intl";
|
|
242
|
-
import { cn as cn4, getUserName as getUserName2 } from "pelatform-ui";
|
|
242
|
+
import { cn as cn4, formatDate, getUserName as getUserName2 } from "pelatform-ui";
|
|
243
243
|
import { Skeleton as Skeleton2 } from "pelatform-ui/default";
|
|
244
244
|
|
|
245
245
|
// src/components/avatar.tsx
|
|
@@ -419,16 +419,18 @@ function UserView({ className, classNames, isPending, size, user }) {
|
|
|
419
419
|
] });
|
|
420
420
|
}
|
|
421
421
|
function ApiKeyView({ className, classNames, apiKey }) {
|
|
422
|
-
const t = useTranslations6();
|
|
423
422
|
const locale = useLocale2();
|
|
423
|
+
const t = useTranslations6();
|
|
424
424
|
const formatExpiration = () => {
|
|
425
425
|
if (!apiKey.expiresAt) return t("common.time.neverExpires");
|
|
426
|
-
const expiresDate =
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
426
|
+
const expiresDate = formatDate(
|
|
427
|
+
new Date(apiKey.expiresAt),
|
|
428
|
+
{
|
|
429
|
+
month: "short"
|
|
430
|
+
},
|
|
431
|
+
locale ?? "en"
|
|
432
|
+
);
|
|
433
|
+
return `${t("common.time.expires")} ${expiresDate}`;
|
|
432
434
|
};
|
|
433
435
|
return /* @__PURE__ */ jsxs6("div", { className: cn4("flex items-center gap-3 truncate", className, classNames?.base), children: [
|
|
434
436
|
/* @__PURE__ */ jsx8(KeyRoundIcon, { className: cn4("size-4 shrink-0", classNames?.icon) }),
|
|
@@ -1592,6 +1594,121 @@ function PasswordInput({
|
|
|
1592
1594
|
] })
|
|
1593
1595
|
] });
|
|
1594
1596
|
}
|
|
1597
|
+
|
|
1598
|
+
// src/lib/social-providers.ts
|
|
1599
|
+
import { Icons } from "pelatform-ui";
|
|
1600
|
+
var socialProviders = [
|
|
1601
|
+
{
|
|
1602
|
+
provider: "apple",
|
|
1603
|
+
name: "Apple",
|
|
1604
|
+
icon: Icons.Apple
|
|
1605
|
+
},
|
|
1606
|
+
{
|
|
1607
|
+
provider: "discord",
|
|
1608
|
+
name: "Discord",
|
|
1609
|
+
icon: Icons.Discord
|
|
1610
|
+
},
|
|
1611
|
+
{
|
|
1612
|
+
provider: "dropbox",
|
|
1613
|
+
name: "Dropbox",
|
|
1614
|
+
icon: Icons.Dropbox
|
|
1615
|
+
},
|
|
1616
|
+
{
|
|
1617
|
+
provider: "facebook",
|
|
1618
|
+
name: "Facebook",
|
|
1619
|
+
icon: Icons.FacebookColorful
|
|
1620
|
+
},
|
|
1621
|
+
{
|
|
1622
|
+
provider: "github",
|
|
1623
|
+
name: "GitHub",
|
|
1624
|
+
icon: Icons.Github
|
|
1625
|
+
},
|
|
1626
|
+
{
|
|
1627
|
+
provider: "gitlab",
|
|
1628
|
+
name: "GitLab",
|
|
1629
|
+
icon: Icons.Gitlab
|
|
1630
|
+
},
|
|
1631
|
+
{
|
|
1632
|
+
provider: "google",
|
|
1633
|
+
name: "Google",
|
|
1634
|
+
icon: Icons.GoogleColorful
|
|
1635
|
+
},
|
|
1636
|
+
{
|
|
1637
|
+
provider: "huggingface",
|
|
1638
|
+
name: "Hugging Face",
|
|
1639
|
+
icon: Icons.Huggingface
|
|
1640
|
+
},
|
|
1641
|
+
{
|
|
1642
|
+
provider: "kick",
|
|
1643
|
+
name: "Kick",
|
|
1644
|
+
icon: Icons.Kick
|
|
1645
|
+
},
|
|
1646
|
+
{
|
|
1647
|
+
provider: "linear",
|
|
1648
|
+
name: "Linear",
|
|
1649
|
+
icon: Icons.Linear
|
|
1650
|
+
},
|
|
1651
|
+
{
|
|
1652
|
+
provider: "linkedin",
|
|
1653
|
+
name: "LinkedIn",
|
|
1654
|
+
icon: Icons.LinkedinColorful
|
|
1655
|
+
},
|
|
1656
|
+
{
|
|
1657
|
+
provider: "microsoft",
|
|
1658
|
+
name: "Microsoft",
|
|
1659
|
+
icon: Icons.Microsoft
|
|
1660
|
+
},
|
|
1661
|
+
{
|
|
1662
|
+
provider: "notion",
|
|
1663
|
+
name: "Notion",
|
|
1664
|
+
icon: Icons.Notion
|
|
1665
|
+
},
|
|
1666
|
+
{
|
|
1667
|
+
provider: "reddit",
|
|
1668
|
+
name: "Reddit",
|
|
1669
|
+
icon: Icons.Reddit
|
|
1670
|
+
},
|
|
1671
|
+
{
|
|
1672
|
+
provider: "roblox",
|
|
1673
|
+
name: "Roblox",
|
|
1674
|
+
icon: Icons.Roblox
|
|
1675
|
+
},
|
|
1676
|
+
{
|
|
1677
|
+
provider: "slack",
|
|
1678
|
+
name: "Slack",
|
|
1679
|
+
icon: Icons.Slack
|
|
1680
|
+
},
|
|
1681
|
+
{
|
|
1682
|
+
provider: "spotify",
|
|
1683
|
+
name: "Spotify",
|
|
1684
|
+
icon: Icons.Spotify
|
|
1685
|
+
},
|
|
1686
|
+
{
|
|
1687
|
+
provider: "tiktok",
|
|
1688
|
+
name: "TikTok",
|
|
1689
|
+
icon: Icons.Tiktok
|
|
1690
|
+
},
|
|
1691
|
+
{
|
|
1692
|
+
provider: "twitch",
|
|
1693
|
+
name: "Twitch",
|
|
1694
|
+
icon: Icons.Twitch
|
|
1695
|
+
},
|
|
1696
|
+
{
|
|
1697
|
+
provider: "vk",
|
|
1698
|
+
name: "VK",
|
|
1699
|
+
icon: Icons.Vk
|
|
1700
|
+
},
|
|
1701
|
+
{
|
|
1702
|
+
provider: "twitter",
|
|
1703
|
+
name: "X",
|
|
1704
|
+
icon: Icons.X
|
|
1705
|
+
},
|
|
1706
|
+
{
|
|
1707
|
+
provider: "zoom",
|
|
1708
|
+
name: "Zoom",
|
|
1709
|
+
icon: Icons.Zoom
|
|
1710
|
+
}
|
|
1711
|
+
];
|
|
1595
1712
|
export {
|
|
1596
1713
|
ApiKeyView,
|
|
1597
1714
|
AuthLayout,
|
|
@@ -1633,5 +1750,6 @@ export {
|
|
|
1633
1750
|
UserMenu,
|
|
1634
1751
|
UserView,
|
|
1635
1752
|
WorkspaceLogo,
|
|
1636
|
-
WorkspaceView
|
|
1753
|
+
WorkspaceView,
|
|
1754
|
+
socialProviders
|
|
1637
1755
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pelatform/starter.shared",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.4",
|
|
4
4
|
"description": "A part of SaaS starter kit for Pelatform applications.",
|
|
5
5
|
"author": "Pelatform",
|
|
6
6
|
"license": "MIT",
|
|
@@ -13,10 +13,6 @@
|
|
|
13
13
|
".": {
|
|
14
14
|
"types": "./dist/index.d.ts",
|
|
15
15
|
"default": "./dist/index.js"
|
|
16
|
-
},
|
|
17
|
-
"./extend": {
|
|
18
|
-
"types": "./dist/extend.d.ts",
|
|
19
|
-
"default": "./dist/extend.js"
|
|
20
16
|
}
|
|
21
17
|
},
|
|
22
18
|
"scripts": {
|
|
@@ -41,7 +37,7 @@
|
|
|
41
37
|
"devDependencies": {
|
|
42
38
|
"@pelatform/starter.config": "0.2.1",
|
|
43
39
|
"@pelatform/starter.hook": "0.2.1",
|
|
44
|
-
"@pelatform/starter.utils": "0.2.
|
|
40
|
+
"@pelatform/starter.utils": "0.2.3",
|
|
45
41
|
"@pelatform/tsconfig": "^0.1.3",
|
|
46
42
|
"@types/react": "^19.2.7",
|
|
47
43
|
"lucide-react": "^0.561.0",
|
package/dist/extend.d.ts
DELETED
|
@@ -1,107 +0,0 @@
|
|
|
1
|
-
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import * as react from 'react';
|
|
3
|
-
import { ComponentType } from 'react';
|
|
4
|
-
export { A as AvatarClassNames, a as AvatarProps, C as CardClassNames, b as CardComponentProps, D as DialogClassNames, c as DialogComponentProps, V as ViewClassNames, d as ViewProps } from './view-B1v2TRLo.js';
|
|
5
|
-
import 'pelatform-ui/default';
|
|
6
|
-
import '@pelatform/starter.utils';
|
|
7
|
-
|
|
8
|
-
declare const socialProviders: readonly [{
|
|
9
|
-
readonly provider: "apple";
|
|
10
|
-
readonly name: "Apple";
|
|
11
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
12
|
-
}, {
|
|
13
|
-
readonly provider: "discord";
|
|
14
|
-
readonly name: "Discord";
|
|
15
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
16
|
-
}, {
|
|
17
|
-
readonly provider: "dropbox";
|
|
18
|
-
readonly name: "Dropbox";
|
|
19
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
20
|
-
}, {
|
|
21
|
-
readonly provider: "facebook";
|
|
22
|
-
readonly name: "Facebook";
|
|
23
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
24
|
-
}, {
|
|
25
|
-
readonly provider: "github";
|
|
26
|
-
readonly name: "GitHub";
|
|
27
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
28
|
-
}, {
|
|
29
|
-
readonly provider: "gitlab";
|
|
30
|
-
readonly name: "GitLab";
|
|
31
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
32
|
-
}, {
|
|
33
|
-
readonly provider: "google";
|
|
34
|
-
readonly name: "Google";
|
|
35
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
36
|
-
}, {
|
|
37
|
-
readonly provider: "huggingface";
|
|
38
|
-
readonly name: "Hugging Face";
|
|
39
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
40
|
-
}, {
|
|
41
|
-
readonly provider: "kick";
|
|
42
|
-
readonly name: "Kick";
|
|
43
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
44
|
-
}, {
|
|
45
|
-
readonly provider: "linear";
|
|
46
|
-
readonly name: "Linear";
|
|
47
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
48
|
-
}, {
|
|
49
|
-
readonly provider: "linkedin";
|
|
50
|
-
readonly name: "LinkedIn";
|
|
51
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
52
|
-
}, {
|
|
53
|
-
readonly provider: "microsoft";
|
|
54
|
-
readonly name: "Microsoft";
|
|
55
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
56
|
-
}, {
|
|
57
|
-
readonly provider: "notion";
|
|
58
|
-
readonly name: "Notion";
|
|
59
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
60
|
-
}, {
|
|
61
|
-
readonly provider: "reddit";
|
|
62
|
-
readonly name: "Reddit";
|
|
63
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
64
|
-
}, {
|
|
65
|
-
readonly provider: "roblox";
|
|
66
|
-
readonly name: "Roblox";
|
|
67
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
68
|
-
}, {
|
|
69
|
-
readonly provider: "slack";
|
|
70
|
-
readonly name: "Slack";
|
|
71
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
72
|
-
}, {
|
|
73
|
-
readonly provider: "spotify";
|
|
74
|
-
readonly name: "Spotify";
|
|
75
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
76
|
-
}, {
|
|
77
|
-
readonly provider: "tiktok";
|
|
78
|
-
readonly name: "TikTok";
|
|
79
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
80
|
-
}, {
|
|
81
|
-
readonly provider: "twitch";
|
|
82
|
-
readonly name: "Twitch";
|
|
83
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
84
|
-
}, {
|
|
85
|
-
readonly provider: "vk";
|
|
86
|
-
readonly name: "VK";
|
|
87
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
88
|
-
}, {
|
|
89
|
-
readonly provider: "twitter";
|
|
90
|
-
readonly name: "X";
|
|
91
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
92
|
-
}, {
|
|
93
|
-
readonly provider: "zoom";
|
|
94
|
-
readonly name: "Zoom";
|
|
95
|
-
readonly icon: (props: react.HTMLAttributes<SVGElement>) => react_jsx_runtime.JSX.Element;
|
|
96
|
-
}];
|
|
97
|
-
|
|
98
|
-
type ProviderIcon = ComponentType<{
|
|
99
|
-
className?: string;
|
|
100
|
-
}>;
|
|
101
|
-
type Provider = {
|
|
102
|
-
provider: string;
|
|
103
|
-
name: string;
|
|
104
|
-
icon?: ProviderIcon;
|
|
105
|
-
};
|
|
106
|
-
|
|
107
|
-
export { type Provider, type ProviderIcon, socialProviders };
|
package/dist/extend.js
DELETED
|
@@ -1,117 +0,0 @@
|
|
|
1
|
-
// src/lib/social-providers.ts
|
|
2
|
-
import { Icons } from "pelatform-ui";
|
|
3
|
-
var socialProviders = [
|
|
4
|
-
{
|
|
5
|
-
provider: "apple",
|
|
6
|
-
name: "Apple",
|
|
7
|
-
icon: Icons.Apple
|
|
8
|
-
},
|
|
9
|
-
{
|
|
10
|
-
provider: "discord",
|
|
11
|
-
name: "Discord",
|
|
12
|
-
icon: Icons.Discord
|
|
13
|
-
},
|
|
14
|
-
{
|
|
15
|
-
provider: "dropbox",
|
|
16
|
-
name: "Dropbox",
|
|
17
|
-
icon: Icons.Dropbox
|
|
18
|
-
},
|
|
19
|
-
{
|
|
20
|
-
provider: "facebook",
|
|
21
|
-
name: "Facebook",
|
|
22
|
-
icon: Icons.FacebookColorful
|
|
23
|
-
},
|
|
24
|
-
{
|
|
25
|
-
provider: "github",
|
|
26
|
-
name: "GitHub",
|
|
27
|
-
icon: Icons.Github
|
|
28
|
-
},
|
|
29
|
-
{
|
|
30
|
-
provider: "gitlab",
|
|
31
|
-
name: "GitLab",
|
|
32
|
-
icon: Icons.Gitlab
|
|
33
|
-
},
|
|
34
|
-
{
|
|
35
|
-
provider: "google",
|
|
36
|
-
name: "Google",
|
|
37
|
-
icon: Icons.GoogleColorful
|
|
38
|
-
},
|
|
39
|
-
{
|
|
40
|
-
provider: "huggingface",
|
|
41
|
-
name: "Hugging Face",
|
|
42
|
-
icon: Icons.Huggingface
|
|
43
|
-
},
|
|
44
|
-
{
|
|
45
|
-
provider: "kick",
|
|
46
|
-
name: "Kick",
|
|
47
|
-
icon: Icons.Kick
|
|
48
|
-
},
|
|
49
|
-
{
|
|
50
|
-
provider: "linear",
|
|
51
|
-
name: "Linear",
|
|
52
|
-
icon: Icons.Linear
|
|
53
|
-
},
|
|
54
|
-
{
|
|
55
|
-
provider: "linkedin",
|
|
56
|
-
name: "LinkedIn",
|
|
57
|
-
icon: Icons.LinkedinColorful
|
|
58
|
-
},
|
|
59
|
-
{
|
|
60
|
-
provider: "microsoft",
|
|
61
|
-
name: "Microsoft",
|
|
62
|
-
icon: Icons.Microsoft
|
|
63
|
-
},
|
|
64
|
-
{
|
|
65
|
-
provider: "notion",
|
|
66
|
-
name: "Notion",
|
|
67
|
-
icon: Icons.Notion
|
|
68
|
-
},
|
|
69
|
-
{
|
|
70
|
-
provider: "reddit",
|
|
71
|
-
name: "Reddit",
|
|
72
|
-
icon: Icons.Reddit
|
|
73
|
-
},
|
|
74
|
-
{
|
|
75
|
-
provider: "roblox",
|
|
76
|
-
name: "Roblox",
|
|
77
|
-
icon: Icons.Roblox
|
|
78
|
-
},
|
|
79
|
-
{
|
|
80
|
-
provider: "slack",
|
|
81
|
-
name: "Slack",
|
|
82
|
-
icon: Icons.Slack
|
|
83
|
-
},
|
|
84
|
-
{
|
|
85
|
-
provider: "spotify",
|
|
86
|
-
name: "Spotify",
|
|
87
|
-
icon: Icons.Spotify
|
|
88
|
-
},
|
|
89
|
-
{
|
|
90
|
-
provider: "tiktok",
|
|
91
|
-
name: "TikTok",
|
|
92
|
-
icon: Icons.Tiktok
|
|
93
|
-
},
|
|
94
|
-
{
|
|
95
|
-
provider: "twitch",
|
|
96
|
-
name: "Twitch",
|
|
97
|
-
icon: Icons.Twitch
|
|
98
|
-
},
|
|
99
|
-
{
|
|
100
|
-
provider: "vk",
|
|
101
|
-
name: "VK",
|
|
102
|
-
icon: Icons.Vk
|
|
103
|
-
},
|
|
104
|
-
{
|
|
105
|
-
provider: "twitter",
|
|
106
|
-
name: "X",
|
|
107
|
-
icon: Icons.X
|
|
108
|
-
},
|
|
109
|
-
{
|
|
110
|
-
provider: "zoom",
|
|
111
|
-
name: "Zoom",
|
|
112
|
-
icon: Icons.Zoom
|
|
113
|
-
}
|
|
114
|
-
];
|
|
115
|
-
export {
|
|
116
|
-
socialProviders
|
|
117
|
-
};
|
package/dist/view-B1v2TRLo.d.ts
DELETED
|
@@ -1,96 +0,0 @@
|
|
|
1
|
-
import { ComponentProps, ReactNode } from 'react';
|
|
2
|
-
import { Avatar, buttonVariants, Dialog, Card } from 'pelatform-ui/default';
|
|
3
|
-
import { User, Workspace } from '@pelatform/starter.utils';
|
|
4
|
-
|
|
5
|
-
type AvatarClassNames = {
|
|
6
|
-
base?: string;
|
|
7
|
-
fallback?: string;
|
|
8
|
-
fallbackIcon?: string;
|
|
9
|
-
image?: string;
|
|
10
|
-
skeleton?: string;
|
|
11
|
-
};
|
|
12
|
-
interface AvatarProps extends ComponentProps<typeof Avatar> {
|
|
13
|
-
className?: string;
|
|
14
|
-
classNames?: AvatarClassNames;
|
|
15
|
-
image?: string;
|
|
16
|
-
isPending?: boolean;
|
|
17
|
-
size?: NonNullable<Parameters<typeof buttonVariants>[0]>["size"] | null | undefined;
|
|
18
|
-
user?: Partial<User> | null;
|
|
19
|
-
workspace?: Partial<Workspace> | null;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
type DialogClassNames = {
|
|
23
|
-
content?: string;
|
|
24
|
-
header?: string;
|
|
25
|
-
footer?: string;
|
|
26
|
-
};
|
|
27
|
-
interface DialogComponentProps extends ComponentProps<typeof Dialog> {
|
|
28
|
-
className?: string;
|
|
29
|
-
children?: ReactNode;
|
|
30
|
-
classNames?: CardClassNames;
|
|
31
|
-
title?: string;
|
|
32
|
-
description?: string;
|
|
33
|
-
disableFooter?: boolean;
|
|
34
|
-
cancelButton?: boolean;
|
|
35
|
-
cancelButtonDisabled?: boolean;
|
|
36
|
-
button?: ReactNode;
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
type CardClassNames = {
|
|
40
|
-
base?: string;
|
|
41
|
-
cell?: string;
|
|
42
|
-
content?: string;
|
|
43
|
-
header?: string;
|
|
44
|
-
footer?: string;
|
|
45
|
-
grid?: string;
|
|
46
|
-
skeleton?: string;
|
|
47
|
-
title?: string;
|
|
48
|
-
description?: string;
|
|
49
|
-
instructions?: string;
|
|
50
|
-
error?: string;
|
|
51
|
-
label?: string;
|
|
52
|
-
input?: string;
|
|
53
|
-
checkbox?: string;
|
|
54
|
-
icon?: string;
|
|
55
|
-
button?: string;
|
|
56
|
-
primaryButton?: string;
|
|
57
|
-
secondaryButton?: string;
|
|
58
|
-
outlineButton?: string;
|
|
59
|
-
destructiveButton?: string;
|
|
60
|
-
avatar?: AvatarClassNames;
|
|
61
|
-
dialog?: DialogClassNames;
|
|
62
|
-
};
|
|
63
|
-
interface CardComponentProps extends Omit<ComponentProps<typeof Card>, "title" | "variant"> {
|
|
64
|
-
className?: string;
|
|
65
|
-
children?: ReactNode;
|
|
66
|
-
classNames?: CardClassNames;
|
|
67
|
-
title?: ReactNode;
|
|
68
|
-
description?: ReactNode;
|
|
69
|
-
instructions?: ReactNode;
|
|
70
|
-
actionLabel?: ReactNode;
|
|
71
|
-
action?: () => Promise<unknown> | unknown;
|
|
72
|
-
disabled?: boolean;
|
|
73
|
-
isDestructive?: boolean;
|
|
74
|
-
isPending?: boolean;
|
|
75
|
-
isSubmitting?: boolean;
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
type ViewClassNames = {
|
|
79
|
-
base?: string;
|
|
80
|
-
content?: string;
|
|
81
|
-
title?: string;
|
|
82
|
-
subtitle?: string;
|
|
83
|
-
skeleton?: string;
|
|
84
|
-
icon?: string;
|
|
85
|
-
avatar?: AvatarClassNames;
|
|
86
|
-
};
|
|
87
|
-
interface ViewProps {
|
|
88
|
-
className?: string;
|
|
89
|
-
classNames?: ViewClassNames;
|
|
90
|
-
isPending?: boolean;
|
|
91
|
-
size?: NonNullable<Parameters<typeof buttonVariants>[0]>["size"] | null | undefined;
|
|
92
|
-
user?: Partial<User> | null;
|
|
93
|
-
workspace?: Partial<Workspace> | null;
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
export type { AvatarClassNames as A, CardClassNames as C, DialogClassNames as D, ViewClassNames as V, AvatarProps as a, CardComponentProps as b, DialogComponentProps as c, ViewProps as d };
|