@djangocfg/layouts 2.1.115 → 2.1.116

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@djangocfg/layouts",
3
- "version": "2.1.115",
3
+ "version": "2.1.116",
4
4
  "description": "Simple, straightforward layout components for Next.js - import and use with props",
5
5
  "keywords": [
6
6
  "layouts",
@@ -74,12 +74,12 @@
74
74
  "check": "tsc --noEmit"
75
75
  },
76
76
  "peerDependencies": {
77
- "@djangocfg/api": "^2.1.115",
78
- "@djangocfg/centrifugo": "^2.1.115",
79
- "@djangocfg/i18n": "^2.1.115",
80
- "@djangocfg/ui-core": "^2.1.115",
81
- "@djangocfg/ui-nextjs": "^2.1.115",
82
- "@djangocfg/ui-tools": "^2.1.115",
77
+ "@djangocfg/api": "^2.1.116",
78
+ "@djangocfg/centrifugo": "^2.1.116",
79
+ "@djangocfg/i18n": "^2.1.116",
80
+ "@djangocfg/ui-core": "^2.1.116",
81
+ "@djangocfg/ui-nextjs": "^2.1.116",
82
+ "@djangocfg/ui-tools": "^2.1.116",
83
83
  "@hookform/resolvers": "^5.2.2",
84
84
  "consola": "^3.4.2",
85
85
  "lucide-react": "^0.545.0",
@@ -102,13 +102,13 @@
102
102
  "uuid": "^11.1.0"
103
103
  },
104
104
  "devDependencies": {
105
- "@djangocfg/api": "^2.1.115",
106
- "@djangocfg/i18n": "^2.1.115",
107
- "@djangocfg/centrifugo": "^2.1.115",
108
- "@djangocfg/typescript-config": "^2.1.115",
109
- "@djangocfg/ui-core": "^2.1.115",
110
- "@djangocfg/ui-nextjs": "^2.1.115",
111
- "@djangocfg/ui-tools": "^2.1.115",
105
+ "@djangocfg/api": "^2.1.116",
106
+ "@djangocfg/i18n": "^2.1.116",
107
+ "@djangocfg/centrifugo": "^2.1.116",
108
+ "@djangocfg/typescript-config": "^2.1.116",
109
+ "@djangocfg/ui-core": "^2.1.116",
110
+ "@djangocfg/ui-nextjs": "^2.1.116",
111
+ "@djangocfg/ui-tools": "^2.1.116",
112
112
  "@types/node": "^24.7.2",
113
113
  "@types/react": "^19.1.0",
114
114
  "@types/react-dom": "^19.1.0",
@@ -29,6 +29,7 @@ export function PublicFooter({
29
29
  copyright: copyrightProp,
30
30
  credits: creditsProp,
31
31
  variant = 'full',
32
+ containerClassName,
32
33
  }: PublicFooterProps) {
33
34
  const isMobile = useIsMobile();
34
35
 
@@ -44,7 +45,7 @@ export function PublicFooter({
44
45
  if (variant === 'simple') {
45
46
  return (
46
47
  <footer className="bg-background border-t border-border mt-auto">
47
- <div className="w-full px-4 py-4">
48
+ <div className={`mx-auto px-4 py-4 ${containerClassName || 'w-full'}`}>
48
49
  <div className="text-center">
49
50
  <div className="text-sm text-muted-foreground">{copyright}</div>
50
51
  </div>
@@ -53,6 +54,70 @@ export function PublicFooter({
53
54
  );
54
55
  }
55
56
 
57
+ // Compact variant - single line with logo and links
58
+ if (variant === 'compact') {
59
+ return (
60
+ <footer className="bg-background border-t border-border mt-auto">
61
+ <div className={`mx-auto px-4 py-6 ${containerClassName || 'w-full'}`}>
62
+ {/* Main row: logo left, links right */}
63
+ <div className="flex flex-col sm:flex-row items-center justify-between gap-4">
64
+ {/* Logo + Name */}
65
+ <div className="flex items-center gap-3">
66
+ {logo && (
67
+ <img src={logo} alt={siteName} className="h-6 w-6" />
68
+ )}
69
+ <span className="font-medium text-foreground">{siteName}</span>
70
+ </div>
71
+
72
+ {/* Links */}
73
+ {links.length > 0 && (
74
+ <div className="flex flex-wrap items-center justify-center gap-4">
75
+ {links.map((link) =>
76
+ link.external ? (
77
+ <a
78
+ key={link.path}
79
+ href={link.path}
80
+ target="_blank"
81
+ rel="noopener noreferrer"
82
+ className="text-sm text-muted-foreground hover:text-primary transition-colors"
83
+ >
84
+ {link.label}
85
+ </a>
86
+ ) : (
87
+ <Link
88
+ key={link.path}
89
+ href={link.path}
90
+ className="text-sm text-muted-foreground hover:text-primary transition-colors"
91
+ >
92
+ {link.label}
93
+ </Link>
94
+ )
95
+ )}
96
+ </div>
97
+ )}
98
+ </div>
99
+
100
+ {/* Bottom row: copyright + credits */}
101
+ <div className="mt-4 pt-4 border-t border-border flex flex-col sm:flex-row items-center justify-between gap-2 text-xs text-muted-foreground">
102
+ <span>{copyright}</span>
103
+ {credits.url ? (
104
+ <a
105
+ href={credits.url}
106
+ target="_blank"
107
+ rel="noopener noreferrer"
108
+ className="hover:text-primary transition-colors"
109
+ >
110
+ {credits.text}
111
+ </a>
112
+ ) : (
113
+ <span>{credits.text}</span>
114
+ )}
115
+ </div>
116
+ </div>
117
+ </footer>
118
+ );
119
+ }
120
+
56
121
  // Mobile Footer
57
122
  if (isMobile) {
58
123
  return (
@@ -52,6 +52,8 @@ export interface PublicFooterProps {
52
52
  text: string;
53
53
  url?: string;
54
54
  };
55
- /** Variant: full (with all sections) or simple (minimal) */
56
- variant?: 'full' | 'simple';
55
+ /** Variant: full (with all sections), compact (single line with logo and links), or simple (minimal) */
56
+ variant?: 'full' | 'compact' | 'simple';
57
+ /** Custom className for content container (e.g. "max-w-4xl" or "container") */
58
+ containerClassName?: string;
57
59
  }