Skip to content

Commit 8fd37c3

Browse files
authored
Modify landing page (#50)
* Changed main text font, modified top navbar and implemented animations when scrolling to relevent sections. * Again changed little bit of appearence of main text and image. * Added some comments * Main text font made tight and Changed some comments * Changed scroll bar showing in comparison of Jac and Traditional programming. * changed bit of appearance of in that compairing jac and traditional programming. * Byllm blog images restored
1 parent 29fc33f commit 8fd37c3

File tree

2 files changed

+12
-8
lines changed

2 files changed

+12
-8
lines changed

jaseci-org/layouts/components/landing/VerticalTabs.js

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -50,14 +50,18 @@ const VerticalTabs = () => {
5050
setActiveVerticalTab(index);
5151
setActiveLanguage("jac");
5252
};
53-
53+
5454
const currentJacCode = jacTabsData[activeVerticalTab].code;
5555
const currentPythonCode = pythonTabsData[activeVerticalTab].code;
5656

5757
const ANIMATION_DURATION = '0.8s';
5858
const BASE_DELAY = 0.80;
5959
const STAGGER_DELAY = 0.6; // Additional delay between staggered elements
6060

61+
// Calculate line counts for both code snippets
62+
const lineCountJac = currentJacCode.trim().split('\n').length;
63+
const lineCountPython = currentPythonCode.trim().split('\n').length;
64+
6165
// Helper function to get the appropriate animation class
6266
const getTabAnimationName = (index) => {
6367
switch (index) {
@@ -188,13 +192,13 @@ const VerticalTabs = () => {
188192
<div className="flex-1 bg-gradient-to-br from-[#0d1117] to-[#161b22] overflow-hidden">
189193
<div
190194
style={getChildAnimationStyle(1)}
191-
className="h-[420px] overflow-auto custom-scrollbar-orange"
195+
className={`h-[420px] ${lineCountJac > 21 ? 'overflow-auto custom-scrollbar-orange' : ''}`}
192196
>
193197
<div className="flex min-w-full">
194198
{/* Line Numbers - Fixed positioning */}
195199
<div className="bg-[#161b22]/80 border-r border-gray-700/50 flex-shrink-0 select-none sticky left-0 z-10">
196200
<div className="px-3 py-4 font-mono leading-[1.4] text-gray-500" style={{ fontSize: '0.8rem' }}>
197-
{Array.from({ length: Math.max(25, currentJacCode.trim().split('\n').length) }, (_, index) => (
201+
{Array.from({ length: Math.max(21, currentJacCode.trim().split('\n').length) }, (_, index) => (
198202
<div key={index} className="text-right min-h-[1.4em] flex items-center justify-end">
199203
{index + 1}
200204
</div>
@@ -226,7 +230,7 @@ const VerticalTabs = () => {
226230
<div className="flex-1 bg-gradient-to-br from-[#0d1117] to-[#161b22] overflow-hidden">
227231
<div
228232
style={getChildAnimationStyle(1)}
229-
className="h-[420px] overflow-auto custom-scrollbar-blue"
233+
className={`h-[420px] ${lineCountPython > 21 ? 'overflow-auto custom-scrollbar-blue' : ''}`}
230234
>
231235
<div className="flex min-w-full">
232236
{/* Line Numbers - Fixed positioning */}

jaseci-org/layouts/components/landing/WhyWeBuilt.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -106,10 +106,11 @@ const WhyWeBuilt = () => {
106106

107107
<div className="max-w-7xl mx-auto px-2 sm:px-4 lg:px-8 relative z-10">
108108
{/* Header */}
109-
<div
109+
<div
110110
ref={headerRef} // Attach ref for observation
111-
className={`text-center mb-8 sm:mb-12 transition-all duration-700 ease-out ${headerInView ? 'opacity-100 translate-y-0' : 'opacity-0 translate-y-10'
112-
}`}
111+
className={`text-center mb-8 sm:mb-12 transition-all duration-700 ease-out ${
112+
headerInView ? 'opacity-100 translate-y-0' : 'opacity-0 translate-y-10'
113+
}`}
113114
>
114115
<h2 className="text-2xl sm:text-3xl lg:text-4xl font-bold text-white mb-3 bg-gradient-to-r from-white via-blue-400 to-primary-orange bg-clip-text text-transparent">
115116
Why We Built Jaseci
@@ -166,7 +167,6 @@ const WhyWeBuilt = () => {
166167
</div>
167168
</div>
168169

169-
170170
</section>
171171
);
172172
};

0 commit comments

Comments
 (0)