@olwiba/ui 0.0.37 → 0.0.41
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/email/index.d.ts +35 -0
- package/dist/email/index.js +135 -0
- package/dist/email/index.js.map +1 -0
- package/dist/index.d.ts +20 -1
- package/dist/index.js +89 -13
- package/dist/index.js.map +1 -1
- package/package.json +9 -4
- package/src/app/AppShell.tsx +5 -1
- package/src/blog/ChangelogCard.tsx +73 -0
- package/src/blog/ChangelogList.tsx +35 -0
- package/src/email/ActionEmail.tsx +43 -0
- package/src/email/EmailLayout.tsx +96 -0
- package/src/email/EmailLinkFallback.tsx +26 -0
- package/src/email/NoticeEmail.tsx +31 -0
- package/src/email/index.ts +3 -0
- package/src/index.ts +2 -0
- package/src/marketing/ContactSection.tsx +13 -4
- package/src/marketing/Footer.tsx +7 -7
- package/src/marketing/Navbar.tsx +1 -1
- package/src/marketing/NewsletterSection.tsx +8 -0
- package/src/types/external-packages.d.ts +28 -76
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import { ReactNode } from 'react';
|
|
3
|
+
|
|
4
|
+
interface ActionEmailProps {
|
|
5
|
+
appName: string;
|
|
6
|
+
preview: string;
|
|
7
|
+
heading: string;
|
|
8
|
+
description: string;
|
|
9
|
+
actionLabel: string;
|
|
10
|
+
actionUrl: string;
|
|
11
|
+
brandColor?: string;
|
|
12
|
+
showLinkFallback?: boolean;
|
|
13
|
+
}
|
|
14
|
+
declare function ActionEmail({ appName, preview, heading, description, actionLabel, actionUrl, brandColor, showLinkFallback, }: ActionEmailProps): react_jsx_runtime.JSX.Element;
|
|
15
|
+
|
|
16
|
+
interface NoticeEmailProps {
|
|
17
|
+
appName: string;
|
|
18
|
+
preview: string;
|
|
19
|
+
heading: string;
|
|
20
|
+
body: string;
|
|
21
|
+
brandColor?: string;
|
|
22
|
+
}
|
|
23
|
+
declare function NoticeEmail({ appName, preview, heading, body, brandColor, }: NoticeEmailProps): react_jsx_runtime.JSX.Element;
|
|
24
|
+
|
|
25
|
+
interface EmailLayoutProps {
|
|
26
|
+
preview?: string;
|
|
27
|
+
appName: string;
|
|
28
|
+
brandColor?: string;
|
|
29
|
+
children: ReactNode;
|
|
30
|
+
footer?: ReactNode;
|
|
31
|
+
}
|
|
32
|
+
/** Branded email shell — UI block composed from CN primitives. */
|
|
33
|
+
declare function EmailLayout({ preview, appName, brandColor, children, footer, }: EmailLayoutProps): react_jsx_runtime.JSX.Element;
|
|
34
|
+
|
|
35
|
+
export { ActionEmail, type ActionEmailProps, EmailLayout, type EmailLayoutProps, NoticeEmail, type NoticeEmailProps };
|
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
import { EmailRoot, EmailHead, EmailPreview, EmailBody, emailTheme, EmailContainer, EmailSection, EmailText, EmailHeading, EmailButton, EmailLink } from '@olwiba/cn/email';
|
|
2
|
+
import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
|
|
3
|
+
|
|
4
|
+
// src/email/ActionEmail.tsx
|
|
5
|
+
function EmailLayout({
|
|
6
|
+
preview,
|
|
7
|
+
appName,
|
|
8
|
+
brandColor = emailTheme.defaultBrandColor,
|
|
9
|
+
children,
|
|
10
|
+
footer
|
|
11
|
+
}) {
|
|
12
|
+
const year = (/* @__PURE__ */ new Date()).getFullYear();
|
|
13
|
+
return /* @__PURE__ */ jsxs(EmailRoot, { children: [
|
|
14
|
+
/* @__PURE__ */ jsx(EmailHead, {}),
|
|
15
|
+
preview ? /* @__PURE__ */ jsx(EmailPreview, { children: preview }) : null,
|
|
16
|
+
/* @__PURE__ */ jsx(
|
|
17
|
+
EmailBody,
|
|
18
|
+
{
|
|
19
|
+
style: {
|
|
20
|
+
backgroundColor: emailTheme.pageBackground,
|
|
21
|
+
fontFamily: emailTheme.fontFamily,
|
|
22
|
+
margin: 0,
|
|
23
|
+
padding: "24px 0"
|
|
24
|
+
},
|
|
25
|
+
children: /* @__PURE__ */ jsxs(
|
|
26
|
+
EmailContainer,
|
|
27
|
+
{
|
|
28
|
+
style: {
|
|
29
|
+
maxWidth: "560px",
|
|
30
|
+
margin: "0 auto",
|
|
31
|
+
backgroundColor: emailTheme.cardBackground,
|
|
32
|
+
borderRadius: "16px",
|
|
33
|
+
overflow: "hidden",
|
|
34
|
+
border: `1px solid ${emailTheme.cardBorder}`
|
|
35
|
+
},
|
|
36
|
+
children: [
|
|
37
|
+
/* @__PURE__ */ jsx(
|
|
38
|
+
EmailSection,
|
|
39
|
+
{
|
|
40
|
+
style: {
|
|
41
|
+
padding: "24px 32px",
|
|
42
|
+
borderBottom: `1px solid ${emailTheme.cardBorder}`
|
|
43
|
+
},
|
|
44
|
+
children: /* @__PURE__ */ jsx(
|
|
45
|
+
EmailText,
|
|
46
|
+
{
|
|
47
|
+
style: {
|
|
48
|
+
margin: 0,
|
|
49
|
+
fontSize: "18px",
|
|
50
|
+
fontWeight: 600,
|
|
51
|
+
color: brandColor
|
|
52
|
+
},
|
|
53
|
+
children: appName
|
|
54
|
+
}
|
|
55
|
+
)
|
|
56
|
+
}
|
|
57
|
+
),
|
|
58
|
+
/* @__PURE__ */ jsx(EmailSection, { style: { padding: "32px" }, children }),
|
|
59
|
+
footer ?? /* @__PURE__ */ jsx(
|
|
60
|
+
EmailSection,
|
|
61
|
+
{
|
|
62
|
+
style: {
|
|
63
|
+
padding: "20px 32px",
|
|
64
|
+
borderTop: `1px solid ${emailTheme.cardBorder}`,
|
|
65
|
+
backgroundColor: emailTheme.mutedBackground
|
|
66
|
+
},
|
|
67
|
+
children: /* @__PURE__ */ jsxs(
|
|
68
|
+
EmailText,
|
|
69
|
+
{
|
|
70
|
+
variant: "caption",
|
|
71
|
+
style: {
|
|
72
|
+
margin: 0,
|
|
73
|
+
textAlign: "center"
|
|
74
|
+
},
|
|
75
|
+
children: [
|
|
76
|
+
"\xA9 ",
|
|
77
|
+
year,
|
|
78
|
+
" ",
|
|
79
|
+
appName,
|
|
80
|
+
". All rights reserved."
|
|
81
|
+
]
|
|
82
|
+
}
|
|
83
|
+
)
|
|
84
|
+
}
|
|
85
|
+
)
|
|
86
|
+
]
|
|
87
|
+
}
|
|
88
|
+
)
|
|
89
|
+
}
|
|
90
|
+
)
|
|
91
|
+
] });
|
|
92
|
+
}
|
|
93
|
+
function EmailLinkFallback({
|
|
94
|
+
actionUrl,
|
|
95
|
+
label = "Or copy and paste this link into your browser:",
|
|
96
|
+
brandColor
|
|
97
|
+
}) {
|
|
98
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
99
|
+
/* @__PURE__ */ jsx(EmailText, { variant: "caption", style: { margin: "24px 0 8px" }, children: label }),
|
|
100
|
+
/* @__PURE__ */ jsx(EmailText, { style: { margin: 0 }, children: /* @__PURE__ */ jsx(EmailLink, { href: actionUrl, brandColor, children: actionUrl }) })
|
|
101
|
+
] });
|
|
102
|
+
}
|
|
103
|
+
function ActionEmail({
|
|
104
|
+
appName,
|
|
105
|
+
preview,
|
|
106
|
+
heading,
|
|
107
|
+
description,
|
|
108
|
+
actionLabel,
|
|
109
|
+
actionUrl,
|
|
110
|
+
brandColor = emailTheme.defaultBrandColor,
|
|
111
|
+
showLinkFallback = true
|
|
112
|
+
}) {
|
|
113
|
+
return /* @__PURE__ */ jsxs(EmailLayout, { preview, appName, brandColor, children: [
|
|
114
|
+
/* @__PURE__ */ jsx(EmailHeading, { children: heading }),
|
|
115
|
+
/* @__PURE__ */ jsx(EmailText, { variant: "muted", style: { margin: "0 0 24px" }, children: description }),
|
|
116
|
+
/* @__PURE__ */ jsx(EmailButton, { href: actionUrl, label: actionLabel, brandColor }),
|
|
117
|
+
showLinkFallback ? /* @__PURE__ */ jsx(EmailLinkFallback, { actionUrl, brandColor }) : null
|
|
118
|
+
] });
|
|
119
|
+
}
|
|
120
|
+
function NoticeEmail({
|
|
121
|
+
appName,
|
|
122
|
+
preview,
|
|
123
|
+
heading,
|
|
124
|
+
body,
|
|
125
|
+
brandColor = emailTheme.defaultBrandColor
|
|
126
|
+
}) {
|
|
127
|
+
return /* @__PURE__ */ jsxs(EmailLayout, { preview, appName, brandColor, children: [
|
|
128
|
+
/* @__PURE__ */ jsx(EmailHeading, { children: heading }),
|
|
129
|
+
/* @__PURE__ */ jsx(EmailText, { variant: "muted", style: { margin: 0, whiteSpace: "pre-wrap" }, children: body })
|
|
130
|
+
] });
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
export { ActionEmail, EmailLayout, NoticeEmail };
|
|
134
|
+
//# sourceMappingURL=index.js.map
|
|
135
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/email/EmailLayout.tsx","../../src/email/EmailLinkFallback.tsx","../../src/email/ActionEmail.tsx","../../src/email/NoticeEmail.tsx"],"names":["jsxs","jsx","EmailText","emailTheme","EmailHeading"],"mappings":";;;;AAqBO,SAAS,WAAA,CAAY;AAAA,EAC1B,OAAA;AAAA,EACA,OAAA;AAAA,EACA,aAAa,UAAA,CAAW,iBAAA;AAAA,EACxB,QAAA;AAAA,EACA;AACF,CAAA,EAAqB;AACnB,EAAA,MAAM,IAAA,GAAA,iBAAO,IAAI,IAAA,EAAK,EAAE,WAAA,EAAY;AAEpC,EAAA,4BACG,SAAA,EAAA,EACC,QAAA,EAAA;AAAA,oBAAA,GAAA,CAAC,SAAA,EAAA,EAAU,CAAA;AAAA,IACV,OAAA,mBAAU,GAAA,CAAC,YAAA,EAAA,EAAc,QAAA,EAAA,OAAA,EAAQ,CAAA,GAAkB,IAAA;AAAA,oBACpD,GAAA;AAAA,MAAC,SAAA;AAAA,MAAA;AAAA,QACC,KAAA,EAAO;AAAA,UACL,iBAAiB,UAAA,CAAW,cAAA;AAAA,UAC5B,YAAY,UAAA,CAAW,UAAA;AAAA,UACvB,MAAA,EAAQ,CAAA;AAAA,UACR,OAAA,EAAS;AAAA,SACX;AAAA,QAEA,QAAA,kBAAA,IAAA;AAAA,UAAC,c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,MAAA,EAAQ,UAAA,EAAW,EACpD,QAAA,EAAA,WAAA,EACH,CAAA;AAAA,oBACAD,GAAAA,CAAC,WAAA,EAAA,EAAY,MAAM,SAAA,EAAW,KAAA,EAAO,aAAa,UAAA,EAAwB,CAAA;AAAA,IACzE,mCACCA,GAAAA,CAAC,iBAAA,EAAA,EAAkB,SAAA,EAAsB,YAAwB,CAAA,GAC/D;AAAA,GAAA,EACN,CAAA;AAEJ;AC3BO,SAAS,WAAA,CAAY;AAAA,EAC1B,OAAA;AAAA,EACA,OAAA;AAAA,EACA,OAAA;AAAA,EACA,IAAA;AAAA,EACA,aAAaE,UAAAA,CAAW;AAC1B,CAAA,EAAqB;AACnB,EAAA,uBACEH,IAAAA,CAAC,WAAA,EAAA,EAAY,OAAA,EAAkB,SAAkB,UAAA,EAC/C,QAAA,EAAA;AAAA,oBAAAC,GAAAA,CAACG,YAAAA,EAAA,EAAc,QAAA,EAAA,OAAA,EAAQ,CAAA;AAAA,oBACvBH,GAAAA,CAACC,SAAAA,EAAA,EAAU,OAAA,EAAQ,OAAA,EAAQ,KAAA,EAAO,EAAE,MAAA,EAAQ,CAAA,EAAG,UAAA,EAAY,UAAA,IACxD,QAAA,EAAA,IAAA,EACH;AAAA,GAAA,EACF,CAAA;AAEJ","file":"index.js","sourcesContent":["import type { ReactNode } from 'react';\nimport {\n EmailBody,\n EmailContainer,\n EmailHead,\n EmailPreview,\n EmailRoot,\n EmailSection,\n EmailText,\n emailTheme,\n} from '@olwiba/cn/email';\n\nexport interface EmailLayoutProps {\n preview?: string;\n appName: string;\n brandColor?: string;\n children: ReactNode;\n footer?: ReactNode;\n}\n\n/** Branded email shell — UI block composed from CN primitives. */\nexport function EmailLayout({\n preview,\n appName,\n brandColor = emailTheme.defaultBrandColor,\n children,\n footer,\n}: EmailLayoutProps) {\n const year = new Date().getFullYear();\n\n return (\n <EmailRoot>\n <EmailHead />\n {preview ? <EmailPreview>{preview}</EmailPreview> : null}\n <EmailBody\n style={{\n backgroundColor: emailTheme.pageBackground,\n fontFamily: emailTheme.fontFamily,\n margin: 0,\n padding: '24px 0',\n }}\n >\n <EmailContainer\n style={{\n maxWidth: '560px',\n margin: '0 auto',\n backgroundColor: emailTheme.cardBackground,\n borderRadius: '16px',\n overflow: 'hidden',\n border: `1px solid ${emailTheme.cardBorder}`,\n }}\n >\n <EmailSection\n style={{\n padding: '24px 32px',\n borderBottom: `1px solid ${emailTheme.cardBorder}`,\n }}\n >\n <EmailText\n style={{\n margin: 0,\n fontSize: '18px',\n fontWeight: 600,\n color: brandColor,\n }}\n >\n {appName}\n </EmailText>\n </EmailSection>\n\n <EmailSection style={{ padding: '32px' }}>{children}</EmailSection>\n\n {footer ?? (\n <EmailSection\n style={{\n padding: '20px 32px',\n borderTop: `1px solid ${emailTheme.cardBorder}`,\n backgroundColor: emailTheme.mutedBackground,\n }}\n >\n <EmailText\n variant=\"caption\"\n style={{\n margin: 0,\n textAlign: 'center',\n }}\n >\n © {year} {appName}. All rights reserved.\n </EmailText>\n </EmailSection>\n )}\n </EmailContainer>\n </EmailBody>\n </EmailRoot>\n );\n}\n","import { EmailLink, EmailText } from '@olwiba/cn/email';\n\nexport interface EmailLinkFallbackProps {\n actionUrl: string;\n label?: string;\n brandColor?: string;\n}\n\nexport function EmailLinkFallback({\n actionUrl,\n label = 'Or copy and paste this link into your browser:',\n brandColor,\n}: EmailLinkFallbackProps) {\n return (\n <>\n <EmailText variant=\"caption\" style={{ margin: '24px 0 8px' }}>\n {label}\n </EmailText>\n <EmailText style={{ margin: 0 }}>\n <EmailLink href={actionUrl} brandColor={brandColor}>\n {actionUrl}\n </EmailLink>\n </EmailText>\n </>\n );\n}\n","import {\n EmailButton,\n EmailHeading,\n EmailText,\n emailTheme,\n} from '@olwiba/cn/email';\nimport { EmailLayout } from './EmailLayout';\nimport { EmailLinkFallback } from './EmailLinkFallback';\n\nexport interface ActionEmailProps {\n appName: string;\n preview: string;\n heading: string;\n description: string;\n actionLabel: string;\n actionUrl: string;\n brandColor?: string;\n showLinkFallback?: boolean;\n}\n\nexport function ActionEmail({\n appName,\n preview,\n heading,\n description,\n actionLabel,\n actionUrl,\n brandColor = emailTheme.defaultBrandColor,\n showLinkFallback = true,\n}: ActionEmailProps) {\n return (\n <EmailLayout preview={preview} appName={appName} brandColor={brandColor}>\n <EmailHeading>{heading}</EmailHeading>\n <EmailText variant=\"muted\" style={{ margin: '0 0 24px' }}>\n {description}\n </EmailText>\n <EmailButton href={actionUrl} label={actionLabel} brandColor={brandColor} />\n {showLinkFallback ? (\n <EmailLinkFallback actionUrl={actionUrl} brandColor={brandColor} />\n ) : null}\n </EmailLayout>\n );\n}\n","import {\n EmailHeading,\n EmailText,\n emailTheme,\n} from '@olwiba/cn/email';\nimport { EmailLayout } from './EmailLayout';\n\nexport interface NoticeEmailProps {\n appName: string;\n preview: string;\n heading: string;\n body: string;\n brandColor?: string;\n}\n\nexport function NoticeEmail({\n appName,\n preview,\n heading,\n body,\n brandColor = emailTheme.defaultBrandColor,\n}: NoticeEmailProps) {\n return (\n <EmailLayout preview={preview} appName={appName} brandColor={brandColor}>\n <EmailHeading>{heading}</EmailHeading>\n <EmailText variant=\"muted\" style={{ margin: 0, whiteSpace: 'pre-wrap' }}>\n {body}\n </EmailText>\n </EmailLayout>\n );\n}\n"]}
|
package/dist/index.d.ts
CHANGED
|
@@ -814,6 +814,25 @@ interface PostListProps {
|
|
|
814
814
|
}
|
|
815
815
|
declare function PostList({ posts, renderLink, emptyMessage }: PostListProps): react_jsx_runtime.JSX.Element;
|
|
816
816
|
|
|
817
|
+
interface ChangelogCardProps {
|
|
818
|
+
title: string;
|
|
819
|
+
summary: string;
|
|
820
|
+
date: string;
|
|
821
|
+
slug: string;
|
|
822
|
+
version?: string;
|
|
823
|
+
hrefPrefix?: string;
|
|
824
|
+
renderLink?: AppShellRenderLink;
|
|
825
|
+
}
|
|
826
|
+
declare function ChangelogCard({ title, summary, date, slug, version, hrefPrefix, renderLink, }: ChangelogCardProps): react_jsx_runtime.JSX.Element;
|
|
827
|
+
|
|
828
|
+
interface ChangelogListProps {
|
|
829
|
+
entries: ChangelogCardProps[];
|
|
830
|
+
renderLink?: AppShellRenderLink;
|
|
831
|
+
emptyMessage?: string;
|
|
832
|
+
hrefPrefix?: string;
|
|
833
|
+
}
|
|
834
|
+
declare function ChangelogList({ entries, renderLink, emptyMessage, hrefPrefix, }: ChangelogListProps): react_jsx_runtime.JSX.Element;
|
|
835
|
+
|
|
817
836
|
interface MdxContentProps {
|
|
818
837
|
code: string;
|
|
819
838
|
}
|
|
@@ -875,4 +894,4 @@ interface UsePaginationReturn {
|
|
|
875
894
|
}
|
|
876
895
|
declare function usePagination(total: number, pageSize: number): UsePaginationReturn;
|
|
877
896
|
|
|
878
|
-
export { type AppNavItem, AppScreen, AppShell, type AppShellAction, type AppShellBrand, type AppShellProps, type AppShellRenderLink, type AppShellUser, type AuthFormProps, AuthSection, type AuthSectionProps, Badge, type BadgeProps, Button, type ButtonProps, Card, type CardProps, Checkbox, type CheckboxProps, ConfirmDialog, type ConfirmDialogProps, type ConfirmOptions, type ContactInfoItem, ContactSection, type ContactSectionProps, ContextMenu, type ContextMenuDef, type ContextMenuProps, CountUp, type CountUpProps, CtaSection, type CtaSectionProps, DevBanner, type DevBannerProps, Dock, type DockItem, type DockProps, EmptyState, type EmptyStateProps, ErrorPage, type ErrorPageProps, FadeIn, type FadeInProps, FaqSection, type FaqSectionProps, FeatureCard, type FeatureCardProps, FeaturesSection, type FeaturesSectionProps, Footer, type FooterProps, FullPageSpinner, GlassCard, type GlassCardProps, HeroSection, type HeroSectionProps, type Hotkey, ImageCard, type ImageCardProps, Input, type InputProps, LogoStrip, type LogoStripProps, MdxContent, type MdxContentProps, Navbar, type NavbarProps, NewsletterSection, type NewsletterSectionProps, OlwibaUIProvider, type OlwibaUIProviderProps, Overlay, type OverlayProps, type OverlayVariant, PageHeader, type PageHeaderBackButton, type PageHeaderBreadcrumb, type PageHeaderProps, PageTransition, type PageTransitionProps, PhoneFrame, type PhoneFrameProps, PostCard, type PostCardProps, PostList, type PostListProps, PricingCard, type PricingCardProps, type PricingFeature, type PricingPlan, PricingSection, type PricingSectionProps, RegisterHotkeys, RootErrorFallback, SectionTitle, type SectionTitleProps, Spotlight, type SpotlightGroup, type SpotlightItem, type SpotlightProps, StaggerChildren, type StaggerChildrenProps, StatCard, type StatCardProps, StatsSection, type StatsSectionProps, Suspensed, Switch, type SwitchProps, TeamSection, TestimonialCard, type TestimonialCardProps, TestimonialsSection, type TestimonialsSectionProps, Textarea, type TextareaProps, ThemeColorUpdater, ThemeSwitchMinimal, type UIMode, Underlay, type UnderlayProps, type UnderlayVariant, type UpgradeComparisonRow, UpgradePrompt, type UpgradePromptProps, type UseConfirmReturn, type UseControlledOpenReturn, type UsePaginationReturn, VersionBanner, cn, useConfirm, useControlledOpen, useCopyToClipboard, useDebounce, useIntersectionObserver, useLocalStorage, useMediaQuery, useMounted, useOlwibaUI, usePagination, useScrolledPast, useUIMode };
|
|
897
|
+
export { type AppNavItem, AppScreen, AppShell, type AppShellAction, type AppShellBrand, type AppShellProps, type AppShellRenderLink, type AppShellUser, type AuthFormProps, AuthSection, type AuthSectionProps, Badge, type BadgeProps, Button, type ButtonProps, Card, type CardProps, ChangelogCard, type ChangelogCardProps, ChangelogList, type ChangelogListProps, Checkbox, type CheckboxProps, ConfirmDialog, type ConfirmDialogProps, type ConfirmOptions, type ContactInfoItem, ContactSection, type ContactSectionProps, ContextMenu, type ContextMenuDef, type ContextMenuProps, CountUp, type CountUpProps, CtaSection, type CtaSectionProps, DevBanner, type DevBannerProps, Dock, type DockItem, type DockProps, EmptyState, type EmptyStateProps, ErrorPage, type ErrorPageProps, FadeIn, type FadeInProps, FaqSection, type FaqSectionProps, FeatureCard, type FeatureCardProps, FeaturesSection, type FeaturesSectionProps, Footer, type FooterProps, FullPageSpinner, GlassCard, type GlassCardProps, HeroSection, type HeroSectionProps, type Hotkey, ImageCard, type ImageCardProps, Input, type InputProps, LogoStrip, type LogoStripProps, MdxContent, type MdxContentProps, Navbar, type NavbarProps, NewsletterSection, type NewsletterSectionProps, OlwibaUIProvider, type OlwibaUIProviderProps, Overlay, type OverlayProps, type OverlayVariant, PageHeader, type PageHeaderBackButton, type PageHeaderBreadcrumb, type PageHeaderProps, PageTransition, type PageTransitionProps, PhoneFrame, type PhoneFrameProps, PostCard, type PostCardProps, PostList, type PostListProps, PricingCard, type PricingCardProps, type PricingFeature, type PricingPlan, PricingSection, type PricingSectionProps, RegisterHotkeys, RootErrorFallback, SectionTitle, type SectionTitleProps, Spotlight, type SpotlightGroup, type SpotlightItem, type SpotlightProps, StaggerChildren, type StaggerChildrenProps, StatCard, type StatCardProps, StatsSection, type StatsSectionProps, Suspensed, Switch, type SwitchProps, TeamSection, TestimonialCard, type TestimonialCardProps, TestimonialsSection, type TestimonialsSectionProps, Textarea, type TextareaProps, ThemeColorUpdater, ThemeSwitchMinimal, type UIMode, Underlay, type UnderlayProps, type UnderlayVariant, type UpgradeComparisonRow, UpgradePrompt, type UpgradePromptProps, type UseConfirmReturn, type UseControlledOpenReturn, type UsePaginationReturn, VersionBanner, cn, useConfirm, useControlledOpen, useCopyToClipboard, useDebounce, useIntersectionObserver, useLocalStorage, useMediaQuery, useMounted, useOlwibaUI, usePagination, useScrolledPast, useUIMode };
|
package/dist/index.js
CHANGED
|
@@ -153,7 +153,7 @@ function ShellSidebar({
|
|
|
153
153
|
/* @__PURE__ */ jsx(SidebarHeader, { children: /* @__PURE__ */ jsx(SidebarMenu, { children: /* @__PURE__ */ jsx(SidebarMenuItem, { children: /* @__PURE__ */ jsx(SidebarMenuButton, { asChild: true, tooltip: typeof brand.name === "string" ? brand.name : void 0, className: "data-[slot=sidebar-menu-button]:!p-1.5", children: renderLink({
|
|
154
154
|
href: brand.href ?? "#",
|
|
155
155
|
children: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
156
|
-
brand.logo
|
|
156
|
+
brand.logo ? /* @__PURE__ */ jsx("span", { className: "flex size-8 shrink-0 items-center justify-center rounded-lg bg-primary text-primary-foreground", children: brand.logo }) : /* @__PURE__ */ jsx("span", { className: "flex size-4 shrink-0 items-center justify-center text-sm font-semibold", children: fallbackLogo }),
|
|
157
157
|
/* @__PURE__ */ jsx("span", { className: "min-w-0 truncate text-base font-semibold group-data-[collapsible=icon]:hidden", children: brand.name })
|
|
158
158
|
] })
|
|
159
159
|
}) }) }) }) }),
|
|
@@ -1243,6 +1243,17 @@ function NewsletterSection({
|
|
|
1243
1243
|
" ",
|
|
1244
1244
|
/* @__PURE__ */ jsx("span", { className: "text-muted-foreground", children: successDescription })
|
|
1245
1245
|
] }) : /* @__PURE__ */ jsxs("form", { onSubmit: handleSubmit, className: "mt-8 flex flex-col gap-3 sm:flex-row", children: [
|
|
1246
|
+
/* @__PURE__ */ jsx(
|
|
1247
|
+
"input",
|
|
1248
|
+
{
|
|
1249
|
+
type: "text",
|
|
1250
|
+
name: "company",
|
|
1251
|
+
tabIndex: -1,
|
|
1252
|
+
autoComplete: "off",
|
|
1253
|
+
"aria-hidden": "true",
|
|
1254
|
+
className: "hidden"
|
|
1255
|
+
}
|
|
1256
|
+
),
|
|
1246
1257
|
/* @__PURE__ */ jsx(
|
|
1247
1258
|
Input$1,
|
|
1248
1259
|
{
|
|
@@ -1331,23 +1342,34 @@ function ContactSection({
|
|
|
1331
1342
|
] }),
|
|
1332
1343
|
/* @__PURE__ */ jsx(Button$1, { variant: "outline", onClick: () => setSubmitted(false), children: sendAnotherLabel })
|
|
1333
1344
|
] }) : /* @__PURE__ */ jsxs("form", { onSubmit: handleSubmit, className: "space-y-5", children: [
|
|
1345
|
+
/* @__PURE__ */ jsx(
|
|
1346
|
+
"input",
|
|
1347
|
+
{
|
|
1348
|
+
type: "text",
|
|
1349
|
+
name: "company",
|
|
1350
|
+
tabIndex: -1,
|
|
1351
|
+
autoComplete: "off",
|
|
1352
|
+
"aria-hidden": "true",
|
|
1353
|
+
className: "hidden"
|
|
1354
|
+
}
|
|
1355
|
+
),
|
|
1334
1356
|
/* @__PURE__ */ jsxs("div", { className: "grid gap-4 sm:grid-cols-2", children: [
|
|
1335
1357
|
/* @__PURE__ */ jsxs("div", { className: "space-y-1.5", children: [
|
|
1336
1358
|
/* @__PURE__ */ jsx(Label, { htmlFor: "contact-first", children: "First name" }),
|
|
1337
|
-
/* @__PURE__ */ jsx(Input$1, { id: "contact-first", placeholder: "Olivia", required: true })
|
|
1359
|
+
/* @__PURE__ */ jsx(Input$1, { id: "contact-first", name: "firstName", placeholder: "Olivia", required: true })
|
|
1338
1360
|
] }),
|
|
1339
1361
|
/* @__PURE__ */ jsxs("div", { className: "space-y-1.5", children: [
|
|
1340
1362
|
/* @__PURE__ */ jsx(Label, { htmlFor: "contact-last", children: "Last name" }),
|
|
1341
|
-
/* @__PURE__ */ jsx(Input$1, { id: "contact-last", placeholder: "Reed", required: true })
|
|
1363
|
+
/* @__PURE__ */ jsx(Input$1, { id: "contact-last", name: "lastName", placeholder: "Reed", required: true })
|
|
1342
1364
|
] })
|
|
1343
1365
|
] }),
|
|
1344
1366
|
/* @__PURE__ */ jsxs("div", { className: "space-y-1.5", children: [
|
|
1345
1367
|
/* @__PURE__ */ jsx(Label, { htmlFor: "contact-email", children: "Email" }),
|
|
1346
|
-
/* @__PURE__ */ jsx(Input$1, { id: "contact-email", type: "email", placeholder: "olivia@company.com", required: true })
|
|
1368
|
+
/* @__PURE__ */ jsx(Input$1, { id: "contact-email", name: "email", type: "email", placeholder: "olivia@company.com", required: true })
|
|
1347
1369
|
] }),
|
|
1348
1370
|
/* @__PURE__ */ jsxs("div", { className: "space-y-1.5", children: [
|
|
1349
1371
|
/* @__PURE__ */ jsx(Label, { htmlFor: "contact-subject", children: "Subject" }),
|
|
1350
|
-
/* @__PURE__ */ jsx(Input$1, { id: "contact-subject", placeholder: "How can we help?", required: true })
|
|
1372
|
+
/* @__PURE__ */ jsx(Input$1, { id: "contact-subject", name: "subject", placeholder: "How can we help?", required: true })
|
|
1351
1373
|
] }),
|
|
1352
1374
|
/* @__PURE__ */ jsxs("div", { className: "space-y-1.5", children: [
|
|
1353
1375
|
/* @__PURE__ */ jsx(Label, { htmlFor: "contact-message", children: "Message" }),
|
|
@@ -1355,6 +1377,7 @@ function ContactSection({
|
|
|
1355
1377
|
Textarea$1,
|
|
1356
1378
|
{
|
|
1357
1379
|
id: "contact-message",
|
|
1380
|
+
name: "message",
|
|
1358
1381
|
placeholder: "Tell us what you're working on...",
|
|
1359
1382
|
className: "min-h-28 resize-none",
|
|
1360
1383
|
required: true
|
|
@@ -1404,7 +1427,7 @@ function Navbar({
|
|
|
1404
1427
|
renderLink({
|
|
1405
1428
|
href: brandHref,
|
|
1406
1429
|
children: /* @__PURE__ */ jsxs("span", { className: "flex items-center gap-2 font-semibold", children: [
|
|
1407
|
-
brand.logo && /* @__PURE__ */ jsx("span", { className: "flex h-
|
|
1430
|
+
brand.logo && /* @__PURE__ */ jsx("span", { className: "flex h-9 w-9 items-center justify-center rounded-xl bg-primary text-primary-foreground", children: brand.logo }),
|
|
1408
1431
|
/* @__PURE__ */ jsx("span", { children: brand.name })
|
|
1409
1432
|
] })
|
|
1410
1433
|
}),
|
|
@@ -1476,18 +1499,18 @@ function Footer({
|
|
|
1476
1499
|
}) {
|
|
1477
1500
|
const brandHref = brand.href ?? "/";
|
|
1478
1501
|
const copyrightText = legal ?? `\xA9 ${(/* @__PURE__ */ new Date()).getFullYear()} ${brand.name}. All rights reserved.`;
|
|
1479
|
-
return /* @__PURE__ */ jsx("footer", { className: "bg-
|
|
1502
|
+
return /* @__PURE__ */ jsx("footer", { className: "overflow-hidden rounded-2xl border bg-foreground text-background", children: /* @__PURE__ */ jsxs("div", { className: "mx-auto max-w-7xl px-6 py-20 sm:py-24 lg:px-8", children: [
|
|
1480
1503
|
/* @__PURE__ */ jsx("div", { className: "flex justify-center", children: renderLink({
|
|
1481
1504
|
href: brandHref,
|
|
1482
1505
|
className: "flex items-center gap-2",
|
|
1483
1506
|
children: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
1484
|
-
brand.logo && /* @__PURE__ */ jsx("span", { className: "flex h-8 w-8 items-center justify-center rounded-lg bg-
|
|
1485
|
-
/* @__PURE__ */ jsx("span", { className: "text-lg font-semibold text-
|
|
1507
|
+
brand.logo && /* @__PURE__ */ jsx("span", { className: "flex h-8 w-8 items-center justify-center rounded-lg bg-background/10 text-background", children: brand.logo }),
|
|
1508
|
+
/* @__PURE__ */ jsx("span", { className: "text-lg font-semibold text-background", children: brand.name })
|
|
1486
1509
|
] })
|
|
1487
1510
|
}) }),
|
|
1488
1511
|
navLinks && navLinks.length > 0 && /* @__PURE__ */ jsx("nav", { className: "mt-10 flex flex-wrap justify-center gap-x-12 gap-y-3", "aria-label": "Footer", children: navLinks.map(({ label, href }) => /* @__PURE__ */ jsx("div", { children: renderLink({
|
|
1489
1512
|
href,
|
|
1490
|
-
className: "text-sm/6 text-
|
|
1513
|
+
className: "text-sm/6 text-background/70 transition-colors hover:text-background",
|
|
1491
1514
|
children: label
|
|
1492
1515
|
}) }, label)) }),
|
|
1493
1516
|
socialLinks && socialLinks.length > 0 && /* @__PURE__ */ jsx("div", { className: "mt-10 flex justify-center gap-x-10", children: socialLinks.map(({ label, href, icon }) => /* @__PURE__ */ jsx(
|
|
@@ -1495,12 +1518,12 @@ function Footer({
|
|
|
1495
1518
|
{
|
|
1496
1519
|
href,
|
|
1497
1520
|
"aria-label": label,
|
|
1498
|
-
className: "text-
|
|
1521
|
+
className: "text-background/70 transition-colors hover:text-background",
|
|
1499
1522
|
children: icon
|
|
1500
1523
|
},
|
|
1501
1524
|
label
|
|
1502
1525
|
)) }),
|
|
1503
|
-
/* @__PURE__ */ jsx("p", { className: "mt-10 text-center text-sm/6 text-
|
|
1526
|
+
/* @__PURE__ */ jsx("p", { className: "mt-10 text-center text-sm/6 text-background/50", children: copyrightText })
|
|
1504
1527
|
] }) });
|
|
1505
1528
|
}
|
|
1506
1529
|
var speedDuration = {
|
|
@@ -2164,6 +2187,59 @@ function PostList({ posts, renderLink, emptyMessage = "No posts published yet."
|
|
|
2164
2187
|
}
|
|
2165
2188
|
return /* @__PURE__ */ jsx("div", { className: "grid gap-8 sm:grid-cols-2", children: posts.map((post) => /* @__PURE__ */ jsx(PostCard, { ...post, renderLink }, post.slug)) });
|
|
2166
2189
|
}
|
|
2190
|
+
function formatDate2(dateStr) {
|
|
2191
|
+
return new Date(dateStr).toLocaleDateString("en-US", {
|
|
2192
|
+
year: "numeric",
|
|
2193
|
+
month: "long",
|
|
2194
|
+
day: "numeric"
|
|
2195
|
+
});
|
|
2196
|
+
}
|
|
2197
|
+
function ChangelogCard({
|
|
2198
|
+
title,
|
|
2199
|
+
summary,
|
|
2200
|
+
date,
|
|
2201
|
+
slug,
|
|
2202
|
+
version,
|
|
2203
|
+
hrefPrefix = "/changelog",
|
|
2204
|
+
renderLink
|
|
2205
|
+
}) {
|
|
2206
|
+
const href = `${hrefPrefix}/${slug}`;
|
|
2207
|
+
const LinkWrapper = ({
|
|
2208
|
+
children,
|
|
2209
|
+
className
|
|
2210
|
+
}) => renderLink ? renderLink({ href, children, className }) : /* @__PURE__ */ jsx("a", { href, className, children });
|
|
2211
|
+
return /* @__PURE__ */ jsxs("article", { className: "group flex flex-col gap-3 border-b border-border/60 pb-8 last:border-0 last:pb-0", children: [
|
|
2212
|
+
/* @__PURE__ */ jsxs("div", { className: "flex flex-wrap items-center gap-2 text-sm text-muted-foreground", children: [
|
|
2213
|
+
/* @__PURE__ */ jsx("time", { dateTime: date, children: formatDate2(date) }),
|
|
2214
|
+
version && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
2215
|
+
/* @__PURE__ */ jsx("span", { children: "\xB7" }),
|
|
2216
|
+
/* @__PURE__ */ jsx(Badge$1, { variant: "secondary", className: "font-mono text-xs", children: version })
|
|
2217
|
+
] })
|
|
2218
|
+
] }),
|
|
2219
|
+
/* @__PURE__ */ jsx("h2", { className: "text-lg font-semibold leading-snug tracking-tight", children: /* @__PURE__ */ jsx(LinkWrapper, { className: "transition-colors hover:text-primary", children: title }) }),
|
|
2220
|
+
/* @__PURE__ */ jsx("p", { className: cn$1("line-clamp-3 text-sm text-muted-foreground"), children: summary }),
|
|
2221
|
+
/* @__PURE__ */ jsx(LinkWrapper, { className: "text-sm font-medium text-primary hover:underline", children: "Read release notes \u2192" })
|
|
2222
|
+
] });
|
|
2223
|
+
}
|
|
2224
|
+
function ChangelogList({
|
|
2225
|
+
entries,
|
|
2226
|
+
renderLink,
|
|
2227
|
+
emptyMessage = "No changelog entries yet.",
|
|
2228
|
+
hrefPrefix
|
|
2229
|
+
}) {
|
|
2230
|
+
if (entries.length === 0) {
|
|
2231
|
+
return /* @__PURE__ */ jsx("p", { className: "text-sm italic text-muted-foreground", children: emptyMessage });
|
|
2232
|
+
}
|
|
2233
|
+
return /* @__PURE__ */ jsx("div", { className: "flex flex-col gap-8", children: entries.map((entry) => /* @__PURE__ */ jsx(
|
|
2234
|
+
ChangelogCard,
|
|
2235
|
+
{
|
|
2236
|
+
...entry,
|
|
2237
|
+
hrefPrefix,
|
|
2238
|
+
renderLink
|
|
2239
|
+
},
|
|
2240
|
+
entry.slug
|
|
2241
|
+
)) });
|
|
2242
|
+
}
|
|
2167
2243
|
var components = {
|
|
2168
2244
|
h1: ({ className, ...props }) => /* @__PURE__ */ jsx("h1", { className: cn("mt-8 scroll-m-20 text-3xl font-bold tracking-tight text-foreground first:mt-0", className), ...props }),
|
|
2169
2245
|
h2: ({ className, ...props }) => /* @__PURE__ */ jsx("h2", { className: cn("mt-10 scroll-m-20 text-2xl font-semibold tracking-tight text-foreground first:mt-0", className), ...props }),
|
|
@@ -2322,6 +2398,6 @@ function usePagination(total, pageSize) {
|
|
|
2322
2398
|
return { page, pageSize, totalPages, offset, hasPrev: page > 1, hasNext: page < totalPages, goTo, next, prev };
|
|
2323
2399
|
}
|
|
2324
2400
|
|
|
2325
|
-
export { AppScreen, AppShell, AuthSection, Badge, Button, Card, Checkbox, ConfirmDialog, ContactSection, ContextMenu, CountUp, CtaSection, DevBanner, Dock, EmptyState, ErrorPage, FadeIn, FaqSection, FeatureCard, FeaturesSection, Footer, FullPageSpinner, GlassCard, HeroSection, ImageCard, Input, LogoStrip, MdxContent, Navbar, NewsletterSection, OlwibaUIProvider, Overlay, PageHeader, PageTransition, PhoneFrame, PostCard, PostList, PricingCard, PricingSection, RegisterHotkeys, RootErrorFallback, SectionTitle, Spotlight, StaggerChildren, StatCard, StatsSection, Suspensed, Switch, TeamSection, TestimonialCard, TestimonialsSection, Textarea, ThemeColorUpdater, ThemeSwitchMinimal, Underlay, UpgradePrompt, VersionBanner, cn, useConfirm, useControlledOpen, useCopyToClipboard, useDebounce, useIntersectionObserver, useLocalStorage, useMediaQuery, useMounted, useOlwibaUI, usePagination, useScrolledPast, useUIMode };
|
|
2401
|
+
export { AppScreen, AppShell, AuthSection, Badge, Button, Card, ChangelogCard, ChangelogList, Checkbox, ConfirmDialog, ContactSection, ContextMenu, CountUp, CtaSection, DevBanner, Dock, EmptyState, ErrorPage, FadeIn, FaqSection, FeatureCard, FeaturesSection, Footer, FullPageSpinner, GlassCard, HeroSection, ImageCard, Input, LogoStrip, MdxContent, Navbar, NewsletterSection, OlwibaUIProvider, Overlay, PageHeader, PageTransition, PhoneFrame, PostCard, PostList, PricingCard, PricingSection, RegisterHotkeys, RootErrorFallback, SectionTitle, Spotlight, StaggerChildren, StatCard, StatsSection, Suspensed, Switch, TeamSection, TestimonialCard, TestimonialsSection, Textarea, ThemeColorUpdater, ThemeSwitchMinimal, Underlay, UpgradePrompt, VersionBanner, cn, useConfirm, useControlledOpen, useCopyToClipboard, useDebounce, useIntersectionObserver, useLocalStorage, useMediaQuery, useMounted, useOlwibaUI, usePagination, useScrolledPast, useUIMode };
|
|
2326
2402
|
//# sourceMappingURL=index.js.map
|
|
2327
2403
|
//# sourceMappingURL=index.js.map
|