@opensite/ui 0.4.4 → 0.4.6
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/navbar-animated-preview.cjs +97 -58
- package/dist/navbar-animated-preview.d.cts +9 -64
- package/dist/navbar-animated-preview.d.ts +9 -64
- package/dist/navbar-animated-preview.js +97 -58
- package/dist/navbar-centered-menu.cjs +46 -7
- package/dist/navbar-centered-menu.d.cts +7 -11
- package/dist/navbar-centered-menu.d.ts +7 -11
- package/dist/navbar-centered-menu.js +46 -7
- package/dist/navbar-dark-icons.cjs +50 -10
- package/dist/navbar-dark-icons.d.cts +6 -11
- package/dist/navbar-dark-icons.d.ts +6 -11
- package/dist/navbar-dark-icons.js +50 -10
- package/dist/navbar-dropdown-menu.cjs +47 -8
- package/dist/navbar-dropdown-menu.d.cts +8 -12
- package/dist/navbar-dropdown-menu.d.ts +8 -12
- package/dist/navbar-dropdown-menu.js +47 -8
- package/dist/navbar-education-platform.cjs +48 -10
- package/dist/navbar-education-platform.d.cts +6 -11
- package/dist/navbar-education-platform.d.ts +6 -11
- package/dist/navbar-education-platform.js +48 -10
- package/dist/navbar-enterprise-mega.cjs +50 -10
- package/dist/navbar-enterprise-mega.d.cts +7 -37
- package/dist/navbar-enterprise-mega.d.ts +7 -37
- package/dist/navbar-enterprise-mega.js +50 -10
- package/dist/navbar-feature-grid.cjs +47 -8
- package/dist/navbar-feature-grid.d.cts +6 -11
- package/dist/navbar-feature-grid.d.ts +6 -11
- package/dist/navbar-feature-grid.js +47 -8
- package/dist/navbar-floating-pill.cjs +50 -11
- package/dist/navbar-floating-pill.d.cts +6 -11
- package/dist/navbar-floating-pill.d.ts +6 -11
- package/dist/navbar-floating-pill.js +50 -11
- package/dist/navbar-fullscreen-menu.cjs +44 -5
- package/dist/navbar-fullscreen-menu.d.cts +6 -11
- package/dist/navbar-fullscreen-menu.d.ts +6 -11
- package/dist/navbar-fullscreen-menu.js +44 -5
- package/dist/navbar-icon-links.cjs +46 -8
- package/dist/navbar-icon-links.d.cts +9 -11
- package/dist/navbar-icon-links.d.ts +9 -11
- package/dist/navbar-icon-links.js +46 -8
- package/dist/navbar-image-preview.cjs +56 -12
- package/dist/navbar-image-preview.d.cts +11 -17
- package/dist/navbar-image-preview.d.ts +11 -17
- package/dist/navbar-image-preview.js +56 -12
- package/dist/navbar-mega-menu.cjs +69 -20
- package/dist/navbar-mega-menu.d.cts +8 -74
- package/dist/navbar-mega-menu.d.ts +8 -74
- package/dist/navbar-mega-menu.js +69 -20
- package/dist/navbar-multi-column-groups.cjs +47 -11
- package/dist/navbar-multi-column-groups.d.cts +6 -11
- package/dist/navbar-multi-column-groups.d.ts +6 -11
- package/dist/navbar-multi-column-groups.js +47 -11
- package/dist/navbar-platform-resources.cjs +199 -164
- package/dist/navbar-platform-resources.d.cts +7 -37
- package/dist/navbar-platform-resources.d.ts +7 -37
- package/dist/navbar-platform-resources.js +199 -164
- package/dist/navbar-search-focused.cjs +45 -7
- package/dist/navbar-search-focused.d.cts +6 -11
- package/dist/navbar-search-focused.d.ts +6 -11
- package/dist/navbar-search-focused.js +45 -7
- package/dist/navbar-sidebar-mobile.cjs +47 -8
- package/dist/navbar-sidebar-mobile.d.cts +6 -11
- package/dist/navbar-sidebar-mobile.d.ts +6 -11
- package/dist/navbar-sidebar-mobile.js +47 -8
- package/dist/navbar-simple-links.cjs +45 -7
- package/dist/navbar-simple-links.d.cts +6 -11
- package/dist/navbar-simple-links.d.ts +6 -11
- package/dist/navbar-simple-links.js +45 -7
- package/dist/navbar-split-cta.cjs +47 -8
- package/dist/navbar-split-cta.d.cts +6 -11
- package/dist/navbar-split-cta.d.ts +6 -11
- package/dist/navbar-split-cta.js +47 -8
- package/dist/navbar-sticky-compact.cjs +49 -10
- package/dist/navbar-sticky-compact.d.cts +6 -11
- package/dist/navbar-sticky-compact.d.ts +6 -11
- package/dist/navbar-sticky-compact.js +49 -10
- package/dist/navbar-tabbed-sections.cjs +47 -8
- package/dist/navbar-tabbed-sections.d.cts +6 -11
- package/dist/navbar-tabbed-sections.d.ts +6 -11
- package/dist/navbar-tabbed-sections.js +47 -8
- package/dist/navbar-transparent-overlay.cjs +47 -9
- package/dist/navbar-transparent-overlay.d.cts +6 -11
- package/dist/navbar-transparent-overlay.d.ts +6 -11
- package/dist/navbar-transparent-overlay.js +47 -9
- package/dist/registry.cjs +522 -328
- package/dist/registry.js +522 -328
- package/dist/types-COVDidbn.d.cts +119 -0
- package/dist/types-COVDidbn.d.ts +119 -0
- package/package.json +2 -2
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* SHARED TYPE INTERFACES FOR ALL NAVBAR COMPONENTS
|
|
5
|
+
* These types provide a consistent interface across all navbar blocks
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* Logo configuration interface - consistent across all navbars
|
|
9
|
+
*/
|
|
10
|
+
interface LogoConfig {
|
|
11
|
+
/** URL to navigate to when logo is clicked */
|
|
12
|
+
url?: string;
|
|
13
|
+
/** Image source for the logo */
|
|
14
|
+
src?: string;
|
|
15
|
+
/** Desktop-specific image source (for responsive logos) */
|
|
16
|
+
desktopSrc?: string;
|
|
17
|
+
/** Mobile-specific image source (for responsive logos) */
|
|
18
|
+
mobileSrc?: string;
|
|
19
|
+
/** Alt text for the logo image */
|
|
20
|
+
alt?: string;
|
|
21
|
+
/** Text title to display (alternative to image) */
|
|
22
|
+
title?: React.ReactNode;
|
|
23
|
+
/** Additional CSS classes for the logo */
|
|
24
|
+
className?: string;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* Base link item - used across all navbar components
|
|
28
|
+
* Supports both 'href' (preferred) and 'url' (legacy) for URLs
|
|
29
|
+
*/
|
|
30
|
+
interface ILinkItem {
|
|
31
|
+
/** Display text for the link */
|
|
32
|
+
label: React.ReactNode;
|
|
33
|
+
/** Optional description text */
|
|
34
|
+
description?: React.ReactNode;
|
|
35
|
+
/** URL the link navigates to (preferred) */
|
|
36
|
+
href?: string;
|
|
37
|
+
/** URL the link navigates to (legacy, use href instead) */
|
|
38
|
+
url?: string;
|
|
39
|
+
/** Icon element to display */
|
|
40
|
+
icon?: React.ReactNode;
|
|
41
|
+
/** Icon name for DynamicIcon component */
|
|
42
|
+
iconName?: string;
|
|
43
|
+
/** Image URL for visual representation */
|
|
44
|
+
image?: string;
|
|
45
|
+
/** Background color or image for the item */
|
|
46
|
+
background?: string;
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* Group of links with optional metadata
|
|
50
|
+
*/
|
|
51
|
+
interface IMenuLinkGroup {
|
|
52
|
+
/** Group label/title */
|
|
53
|
+
label: React.ReactNode;
|
|
54
|
+
/** Optional group description */
|
|
55
|
+
description?: string;
|
|
56
|
+
/** Optional group image */
|
|
57
|
+
image?: string;
|
|
58
|
+
/** Links within this group */
|
|
59
|
+
links: ILinkItem[];
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* Layout types for mega menu dropdowns
|
|
63
|
+
*
|
|
64
|
+
* LAYOUT OPTIONS FOR AI PAGE BUILDER:
|
|
65
|
+
*
|
|
66
|
+
* 1. "animated-image-preview"
|
|
67
|
+
* - Visual: Grid layout with large image preview on left (360px wide), links list on right
|
|
68
|
+
* - Behavior: Image changes on hover based on which link is being hovered over
|
|
69
|
+
* - Best for: Product showcases, visual content navigation, feature highlights
|
|
70
|
+
*
|
|
71
|
+
* 2. "simple-grid"
|
|
72
|
+
* - Visual: 2-column responsive grid of cards with icons or images
|
|
73
|
+
* - Behavior: Static grid with hover effects on cards
|
|
74
|
+
* - Best for: Feature lists, service offerings, general navigation with icons
|
|
75
|
+
*
|
|
76
|
+
* 3. "list-with-icons"
|
|
77
|
+
* - Visual: Single column list of items with small icons on the left
|
|
78
|
+
* - Behavior: Compact list with hover effects
|
|
79
|
+
* - Best for: Simple navigation, documentation links, resource lists
|
|
80
|
+
*/
|
|
81
|
+
type MegaMenuLayout = "animated-image-preview" | "simple-grid" | "list-with-icons";
|
|
82
|
+
/**
|
|
83
|
+
* Menu link configuration with layout-based dropdown options
|
|
84
|
+
*/
|
|
85
|
+
interface IMenuLink {
|
|
86
|
+
/** Display text for the menu trigger */
|
|
87
|
+
label: React.ReactNode;
|
|
88
|
+
/** Direct link URL (for non-dropdown items) */
|
|
89
|
+
href?: string;
|
|
90
|
+
/** Layout type for dropdown content */
|
|
91
|
+
layout?: MegaMenuLayout;
|
|
92
|
+
/** Links array for dropdown content */
|
|
93
|
+
links?: ILinkItem[];
|
|
94
|
+
/** Grouped links for more complex layouts */
|
|
95
|
+
dropdownGroups?: IMenuLinkGroup[];
|
|
96
|
+
}
|
|
97
|
+
/**
|
|
98
|
+
* Layout variant types for navbar components
|
|
99
|
+
*
|
|
100
|
+
* LAYOUT VARIANT OPTIONS:
|
|
101
|
+
*
|
|
102
|
+
* 1. "fullScreenContainerizedLinks" (default)
|
|
103
|
+
* - Visual: Full-screen navbar with links inside a standard container (responsive max-width)
|
|
104
|
+
* - Behavior: Navbar background spans full width, but logo/links/actions are containerized
|
|
105
|
+
* - Best for: Standard websites with consistent content width
|
|
106
|
+
*
|
|
107
|
+
* 2. "fullScreenFullWidthLinks"
|
|
108
|
+
* - Visual: Full-screen navbar without container constraints on links
|
|
109
|
+
* - Behavior: Navbar and all content span full width with custom padding
|
|
110
|
+
* - Best for: Wide layouts, edge-to-edge designs
|
|
111
|
+
*
|
|
112
|
+
* 3. "floatingBar"
|
|
113
|
+
* - Visual: Floating navbar style with rounded borders and shadow
|
|
114
|
+
* - Behavior: Navbar appears as a floating bar with border-radius and contained width
|
|
115
|
+
* - Best for: Modern, elevated navigation designs
|
|
116
|
+
*/
|
|
117
|
+
type NavbarLayoutVariant = "fullScreenContainerizedLinks" | "fullScreenFullWidthLinks" | "floatingBar";
|
|
118
|
+
|
|
119
|
+
export type { IMenuLink as I, LogoConfig as L, MegaMenuLayout as M, NavbarLayoutVariant as N, IMenuLinkGroup as a, ILinkItem as b };
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* SHARED TYPE INTERFACES FOR ALL NAVBAR COMPONENTS
|
|
5
|
+
* These types provide a consistent interface across all navbar blocks
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* Logo configuration interface - consistent across all navbars
|
|
9
|
+
*/
|
|
10
|
+
interface LogoConfig {
|
|
11
|
+
/** URL to navigate to when logo is clicked */
|
|
12
|
+
url?: string;
|
|
13
|
+
/** Image source for the logo */
|
|
14
|
+
src?: string;
|
|
15
|
+
/** Desktop-specific image source (for responsive logos) */
|
|
16
|
+
desktopSrc?: string;
|
|
17
|
+
/** Mobile-specific image source (for responsive logos) */
|
|
18
|
+
mobileSrc?: string;
|
|
19
|
+
/** Alt text for the logo image */
|
|
20
|
+
alt?: string;
|
|
21
|
+
/** Text title to display (alternative to image) */
|
|
22
|
+
title?: React.ReactNode;
|
|
23
|
+
/** Additional CSS classes for the logo */
|
|
24
|
+
className?: string;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* Base link item - used across all navbar components
|
|
28
|
+
* Supports both 'href' (preferred) and 'url' (legacy) for URLs
|
|
29
|
+
*/
|
|
30
|
+
interface ILinkItem {
|
|
31
|
+
/** Display text for the link */
|
|
32
|
+
label: React.ReactNode;
|
|
33
|
+
/** Optional description text */
|
|
34
|
+
description?: React.ReactNode;
|
|
35
|
+
/** URL the link navigates to (preferred) */
|
|
36
|
+
href?: string;
|
|
37
|
+
/** URL the link navigates to (legacy, use href instead) */
|
|
38
|
+
url?: string;
|
|
39
|
+
/** Icon element to display */
|
|
40
|
+
icon?: React.ReactNode;
|
|
41
|
+
/** Icon name for DynamicIcon component */
|
|
42
|
+
iconName?: string;
|
|
43
|
+
/** Image URL for visual representation */
|
|
44
|
+
image?: string;
|
|
45
|
+
/** Background color or image for the item */
|
|
46
|
+
background?: string;
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* Group of links with optional metadata
|
|
50
|
+
*/
|
|
51
|
+
interface IMenuLinkGroup {
|
|
52
|
+
/** Group label/title */
|
|
53
|
+
label: React.ReactNode;
|
|
54
|
+
/** Optional group description */
|
|
55
|
+
description?: string;
|
|
56
|
+
/** Optional group image */
|
|
57
|
+
image?: string;
|
|
58
|
+
/** Links within this group */
|
|
59
|
+
links: ILinkItem[];
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* Layout types for mega menu dropdowns
|
|
63
|
+
*
|
|
64
|
+
* LAYOUT OPTIONS FOR AI PAGE BUILDER:
|
|
65
|
+
*
|
|
66
|
+
* 1. "animated-image-preview"
|
|
67
|
+
* - Visual: Grid layout with large image preview on left (360px wide), links list on right
|
|
68
|
+
* - Behavior: Image changes on hover based on which link is being hovered over
|
|
69
|
+
* - Best for: Product showcases, visual content navigation, feature highlights
|
|
70
|
+
*
|
|
71
|
+
* 2. "simple-grid"
|
|
72
|
+
* - Visual: 2-column responsive grid of cards with icons or images
|
|
73
|
+
* - Behavior: Static grid with hover effects on cards
|
|
74
|
+
* - Best for: Feature lists, service offerings, general navigation with icons
|
|
75
|
+
*
|
|
76
|
+
* 3. "list-with-icons"
|
|
77
|
+
* - Visual: Single column list of items with small icons on the left
|
|
78
|
+
* - Behavior: Compact list with hover effects
|
|
79
|
+
* - Best for: Simple navigation, documentation links, resource lists
|
|
80
|
+
*/
|
|
81
|
+
type MegaMenuLayout = "animated-image-preview" | "simple-grid" | "list-with-icons";
|
|
82
|
+
/**
|
|
83
|
+
* Menu link configuration with layout-based dropdown options
|
|
84
|
+
*/
|
|
85
|
+
interface IMenuLink {
|
|
86
|
+
/** Display text for the menu trigger */
|
|
87
|
+
label: React.ReactNode;
|
|
88
|
+
/** Direct link URL (for non-dropdown items) */
|
|
89
|
+
href?: string;
|
|
90
|
+
/** Layout type for dropdown content */
|
|
91
|
+
layout?: MegaMenuLayout;
|
|
92
|
+
/** Links array for dropdown content */
|
|
93
|
+
links?: ILinkItem[];
|
|
94
|
+
/** Grouped links for more complex layouts */
|
|
95
|
+
dropdownGroups?: IMenuLinkGroup[];
|
|
96
|
+
}
|
|
97
|
+
/**
|
|
98
|
+
* Layout variant types for navbar components
|
|
99
|
+
*
|
|
100
|
+
* LAYOUT VARIANT OPTIONS:
|
|
101
|
+
*
|
|
102
|
+
* 1. "fullScreenContainerizedLinks" (default)
|
|
103
|
+
* - Visual: Full-screen navbar with links inside a standard container (responsive max-width)
|
|
104
|
+
* - Behavior: Navbar background spans full width, but logo/links/actions are containerized
|
|
105
|
+
* - Best for: Standard websites with consistent content width
|
|
106
|
+
*
|
|
107
|
+
* 2. "fullScreenFullWidthLinks"
|
|
108
|
+
* - Visual: Full-screen navbar without container constraints on links
|
|
109
|
+
* - Behavior: Navbar and all content span full width with custom padding
|
|
110
|
+
* - Best for: Wide layouts, edge-to-edge designs
|
|
111
|
+
*
|
|
112
|
+
* 3. "floatingBar"
|
|
113
|
+
* - Visual: Floating navbar style with rounded borders and shadow
|
|
114
|
+
* - Behavior: Navbar appears as a floating bar with border-radius and contained width
|
|
115
|
+
* - Best for: Modern, elevated navigation designs
|
|
116
|
+
*/
|
|
117
|
+
type NavbarLayoutVariant = "fullScreenContainerizedLinks" | "fullScreenFullWidthLinks" | "floatingBar";
|
|
118
|
+
|
|
119
|
+
export type { IMenuLink as I, LogoConfig as L, MegaMenuLayout as M, NavbarLayoutVariant as N, IMenuLinkGroup as a, ILinkItem as b };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@opensite/ui",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.6",
|
|
4
4
|
"description": "Foundational UI component library for OpenSite Semantic Site Builder with tree-shakable exports and abstract styling",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"react",
|
|
@@ -3345,7 +3345,7 @@
|
|
|
3345
3345
|
"optionalDependencies": {
|
|
3346
3346
|
"valibot": "^1.2.0"
|
|
3347
3347
|
},
|
|
3348
|
-
"packageManager": "pnpm@
|
|
3348
|
+
"packageManager": "pnpm@10.28.1",
|
|
3349
3349
|
"engines": {
|
|
3350
3350
|
"node": ">=18.0.0",
|
|
3351
3351
|
"pnpm": ">=9.0.0"
|