Skip to content

Commit

Permalink
home page conflict fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
Irfan-Ahammed committed Jul 28, 2024
2 parents 63c86ea + f760f60 commit 59ab838
Show file tree
Hide file tree
Showing 22 changed files with 194 additions and 151 deletions.
1 change: 1 addition & 0 deletions .env.sample
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
VITE_TMDB_API_KEY=sample
11 changes: 7 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,17 @@ If you are developing a production application, we recommend updating the config
export default {
// other rules...
parserOptions: {
ecmaVersion: 'latest',
sourceType: 'module',
project: ['./tsconfig.json', './tsconfig.node.json', './tsconfig.app.json'],
ecmaVersion: "latest",
sourceType: "module",
project: ["./tsconfig.json", "./tsconfig.node.json", "./tsconfig.app.json"],
tsconfigRootDir: __dirname,
},
}
};
```

- Replace `plugin:@typescript-eslint/recommended` to `plugin:@typescript-eslint/recommended-type-checked` or `plugin:@typescript-eslint/strict-type-checked`
- Optionally add `plugin:@typescript-eslint/stylistic-type-checked`
- Install [eslint-plugin-react](https://github.com/jsx-eslint/eslint-plugin-react) and add `plugin:react/recommended` & `plugin:react/jsx-runtime` to the `extends` list

https://github.com/creativetimofficial/material-tailwind/issues/528
https://github.com/creativetimofficial/material-tailwind/issues/427
89 changes: 11 additions & 78 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 1 addition & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,25 +20,22 @@
"@capacitor/app": "^6.0.0",
"@capacitor/core": "^6.1.1",
"@material-tailwind/react": "^2.1.9",
"@splidejs/react-splide": "^0.7.12",
"@tanstack/react-query": "^5.51.11",
"@tanstack/react-query-devtools": "^5.51.11",
"@uidotdev/usehooks": "^2.4.1",
"react": "^18.3.1",
"react-dom": "^18.3.1",
"react-hook-form": "^7.52.1",
"react-router-dom": "^6.25.1",
"react-slick": "^0.30.2",
"react-transition-group": "^4.4.5",
"slick-carousel": "^1.8.1",
"xior": "^0.5.5"
},
"devDependencies": {
"@capacitor/assets": "^3.0.5",
"@capacitor/cli": "^6.1.1",
"@tailwindcss/typography": "^0.5.13",
"@tanstack/eslint-plugin-query": "^5.51.12",
"@types/react": "^18.3.3",
"@types/react": "18.2.9",
"@types/react-dom": "^18.3.0",
"@types/react-transition-group": "^4.4.10",
"@typescript-eslint/eslint-plugin": "^7.15.0",
Expand Down
2 changes: 1 addition & 1 deletion src/App.css
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

html,
body {
@apply h-full w-full bg-base-100;
@apply bg-base-100;
}

.page {
Expand Down
53 changes: 26 additions & 27 deletions src/components/GettingStarted/BottomSheet.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,6 @@
import { Button } from "@material-tailwind/react";
import { Options, Splide, SplideSlide } from "@splidejs/react-splide";
import { Button, Carousel } from "@material-tailwind/react";
import { Link } from "react-router-dom";

import "@splidejs/react-splide/css";
import "@splidejs/react-splide/css/core";

const title = (
<>
Bring <span className="text-primary">Free</span> streaming to <br />
Expand All @@ -16,39 +12,42 @@ const features = [
"Movieflix Original content production investment in creating high-quality series and movies trailer.",
"Multiple Device Access Availabilty on smartphones,tablet,smart TVs etc.",
];
const splideOptions: Options = {
perPage: 1,
arrows: false,
classes: {
pagination: "splide__pagination relative my-1",
},
type: "loop",
autoplay: "pause",
};

export default function BottomSheet() {
return (
<div className="absolute bottom-0 left-0 z-10 grid w-full place-content-center p-3 shadow-sm">
<div className="w-full min-w-0 max-w-md rounded-3xl bg-accent p-6 text-center">
<h2 className="my-0">{title}</h2>

<Splide options={splideOptions} aria-label="Features of Movieflix">
<Carousel
autoplay
aria-label="Features of Movieflix"
prevArrow={() => <></>}
nextArrow={() => <></>}
className="h-auto"
navigation={({ setActiveIndex, activeIndex, length }) => (
<div className="absolute bottom-3 left-2/4 z-50 flex -translate-x-2/4 gap-2">
{new Array(length).fill("").map((_, i) => (
<span
key={i}
className={`block h-1 cursor-pointer rounded-2xl transition-all content-[''] ${
activeIndex === i ? "w-8 bg-white" : "w-4 bg-white/50"
}`}
onClick={() => setActiveIndex(i)}
/>
))}
</div>
)}
>
{features.map((feat, i) => (
<SplideSlide data-splide-interval="1000" key={i}>
<p className="mt-1">{feat}</p>
</SplideSlide>
<p key={i} className="mt-1">
{feat}
</p>
))}
</Splide>
</Carousel>

<Link to="/login">
<Button
className="w-full"
placeholder={undefined}
onPointerEnterCapture={undefined}
onPointerLeaveCapture={undefined}
>
Get Started
</Button>
<Button className="w-full">Get Started</Button>
</Link>
</div>
</div>
Expand Down
22 changes: 22 additions & 0 deletions src/components/Home/ActionMovies.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import { movieData } from "./SampleData";

function ActionMovies() {
return (
<div className="">
<h2 className="m-0 ml-4">Actions</h2>
<div className="flex overflow-y-hidden overflow-x-scroll">
{movieData.map((item, i) => (
<div key={i} className="h-48 min-w-28 rounded-xl p-4">
<img
src={item.img}
alt={`Movie ${i}`}
className="m-0 h-full w-full rounded-md object-cover object-center"
/>
</div>
))}
</div>
</div>
);
}

export default ActionMovies;
21 changes: 21 additions & 0 deletions src/components/Home/AdventureMovie.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
import { movieData } from "./SampleData";
function AdventureMovie() {
return (
<div>
<h2 className="m-0 ml-4">Adventure</h2>
<div className="flex overflow-y-hidden overflow-x-scroll">
{movieData.map((item, i) => (
<div key={i} className="h-48 min-w-28 rounded-xl p-4">
<img
src={item.img}
alt={`Movie ${i}`}
className="m-0 h-full w-full rounded-md object-cover object-center"
/>
</div>
))}
</div>
</div>
);
}

export default AdventureMovie;
21 changes: 21 additions & 0 deletions src/components/Home/ComedyMovie.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
import { movieData } from "./SampleData";
function ComedyMovie() {
return (
<div>
<h2 className="m-0 ml-4">Comedy</h2>
<div className="flex overflow-y-hidden overflow-x-scroll">
{movieData.map((item, i) => (
<div key={i} className="h-48 min-w-28 rounded-xl p-4">
<img
src={item.img}
alt={`Movie ${i}`}
className="m-0 h-full w-full rounded-md object-cover object-center"
/>
</div>
))}
</div>
</div>
);
}

export default ComedyMovie;
Loading

0 comments on commit 59ab838

Please sign in to comment.