THEZYZSTUDIO commited on
Commit
0a021fa
·
verified ·
1 Parent(s): 1dccf53

Delete components/navbar.js

Browse files
Files changed (1) hide show
  1. components/navbar.js +0 -171
components/navbar.js DELETED
@@ -1,171 +0,0 @@
1
- class Navbar extends HTMLElement {
2
- constructor() {
3
- super();
4
- }
5
-
6
- connectedCallback() {
7
- this.attachShadow({ mode: 'open' });
8
-
9
- // Styles are internal to Shadow DOM for encapsulation.
10
- // We mimic Tailwind's utility classes with standard CSS.
11
- const styles = `
12
- <style>
13
- @import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700&display=swap');
14
-
15
- :host {
16
- display: block;
17
- position: fixed;
18
- top: 0;
19
- left: 0;
20
- right: 0;
21
- z-index: 50;
22
- background: rgba(255, 255, 255, 0.85);
23
- backdrop-filter: blur(12px);
24
- -webkit-backdrop-filter: blur(12px);
25
- border-bottom: 1px solid rgba(0,0,0,0.05);
26
- height: 70px;
27
- display: flex;
28
- align-items: center;
29
- }
30
-
31
- .container {
32
- max-width: 1280px;
33
- width: 100%;
34
- margin: 0 auto;
35
- padding: 0 1.5rem;
36
- display: flex;
37
- justify-content: space-between;
38
- align-items: center;
39
- }
40
-
41
- .logo {
42
- font-family: 'Inter', sans-serif;
43
- font-weight: 800;
44
- font-size: 1.5rem;
45
- color: #0f172a;
46
- text-decoration: none;
47
- display: flex;
48
- align-items: center;
49
- gap: 0.5rem;
50
- }
51
-
52
- .logo span {
53
- color: #4f46e5; /* Primary Color */
54
- }
55
-
56
- .nav-links {
57
- display: flex;
58
- gap: 2rem;
59
- list-style: none;
60
- margin: 0;
61
- padding: 0;
62
- }
63
-
64
- .nav-links a {
65
- text-decoration: none;
66
- color: #475569;
67
- font-family: 'Inter', sans-serif;
68
- font-weight: 500;
69
- font-size: 0.95rem;
70
- transition: color 0.2s;
71
- }
72
-
73
- .nav-links a:hover {
74
- color: #4f46e5;
75
- }
76
-
77
- .btn-primary {
78
- background-color: #4f46e5;
79
- color: white;
80
- padding: 0.6rem 1.25rem;
81
- border-radius: 0.5rem;
82
- text-decoration: none;
83
- font-family: 'Inter', sans-serif;
84
- font-weight: 600;
85
- font-size: 0.9rem;
86
- transition: background-color 0.2s;
87
- display: inline-flex;
88
- align-items: center;
89
- gap: 0.5rem;
90
- }
91
-
92
- .btn-primary:hover {
93
- background-color: #4338ca;
94
- }
95
-
96
- .menu-toggle {
97
- display: none;
98
- background: none;
99
- border: none;
100
- cursor: pointer;
101
- color: #334155;
102
- }
103
-
104
- @media (max-width: 768px) {
105
- .nav-links {
106
- display: none;
107
- position: absolute;
108
- top: 70px;
109
- left: 0;
110
- right: 0;
111
- background: white;
112
- flex-direction: column;
113
- padding: 2rem;
114
- box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
115
- text-align: center;
116
- }
117
-
118
- .nav-links.active {
119
- display: flex;
120
- }
121
-
122
- .menu-toggle {
123
- display: block;
124
- }
125
-
126
- .desktop-cta {
127
- display: none;
128
- }
129
- }
130
- </style>
131
- `;
132
-
133
- this.shadowRoot.innerHTML = `
134
- ${styles}
135
- <nav class="container">
136
- <a href="#" class="logo">
137
- <svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="#4f46e5" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"></circle><polygon points="16.24 7.76 14.12 14.12 7.76 16.24 9.88 9.88 16.24 7.76"></polygon></svg>
138
- Nebula<span>Nexus</span>
139
- </a>
140
-
141
- <button class="menu-toggle">
142
- <svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="3" y1="12" x2="21" y2="12"></line><line x1="3" y1="6" x2="21" y2="6"></line><line x1="3" y1="18" x2="21" y2="18"></line></svg>
143
- </button>
144
-
145
- <ul class="nav-links">
146
- <li><a href="#">Features</a></li>
147
- <li><a href="#">Solutions</a></li>
148
- <li><a href="#">Resources</a></li>
149
- <li><a href="#">Pricing</a></li>
150
- </ul>
151
-
152
- <div class="desktop-cta">
153
- <a href="#" class="btn-primary">
154
- Get Started
155
- <svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="5" y1="12" x2="19" y2="12"></line><polyline points="12 5 19 12 12 19"></polyline></svg>
156
- </a>
157
- </div>
158
- </nav>
159
- `;
160
-
161
- // Mobile Menu Logic
162
- const toggleBtn = this.shadowRoot.querySelector('.menu-toggle');
163
- const navLinks = this.shadowRoot.querySelector('.nav-links');
164
-
165
- toggleBtn.addEventListener('click', () => {
166
- navLinks.classList.toggle('active');
167
- });
168
- }
169
- }
170
-
171
- customElements.define('app-navbar', Navbar);