diff --git a/.gitignore b/.gitignore index 2d513a0..a2b99ea 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ /.idea/ /target/ +/src/main/resources/hibernate.cfg.xml diff --git a/src/main/resources/hibernate.cfg.xml b/src/main/resources/hibernate.cfg.xml deleted file mode 100644 index 8bfcb25..0000000 --- a/src/main/resources/hibernate.cfg.xml +++ /dev/null @@ -1,29 +0,0 @@ - - - - - - - org.hibernate.dialect.MariaDBDialect - - - - org.mariadb.jdbc.Driver - - - - - - jdbc:mariadb://localhost:3306/filmflix - - - - filmflix - - - - filmflix - - - \ No newline at end of file diff --git a/src/main/webapp/assets/logo.png b/src/main/webapp/assets/logo.png new file mode 100644 index 0000000..6f8b19d Binary files /dev/null and b/src/main/webapp/assets/logo.png differ diff --git a/src/main/webapp/css/main.css b/src/main/webapp/css/main.css new file mode 100644 index 0000000..6615132 --- /dev/null +++ b/src/main/webapp/css/main.css @@ -0,0 +1,51 @@ +:root { + --main-color: #E50914; +} + +* { + color: white; + font-family: 'Montserrat', sans-serif; +} + +body { + background-color: black; +} + +main { + min-height: calc(100vh - 4rem); +} + +.color-text { + color: var(--main-color); +} + +.color-border { + border-color: var(--main-color) !important; +} + +.title { + color: var(--main-color); + text-align: center; + + display: -webkit-box; + -webkit-line-clamp: 1; + -webkit-box-orient: vertical; + overflow: hidden; +} + +.title:hover { + display: block; + overflow: unset; +} + +.description-4 { + display: -webkit-box; + -webkit-line-clamp: 4; + -webkit-box-orient: vertical; + overflow: hidden; +} + +.description-4:hover { + display: block; + overflow: unset; +} \ No newline at end of file diff --git a/src/main/webapp/favicon.ico b/src/main/webapp/favicon.ico new file mode 100644 index 0000000..df58ad1 Binary files /dev/null and b/src/main/webapp/favicon.ico differ diff --git a/src/main/webapp/index.jsp b/src/main/webapp/index.jsp index c38169b..6ae2bc8 100644 --- a/src/main/webapp/index.jsp +++ b/src/main/webapp/index.jsp @@ -1,5 +1,43 @@ + + + + + + + + FilmFlix + -

Hello World!

+
+
+
+ FilmFlix logo +
+ +
+ +
+
+
+ + + + + + diff --git a/src/main/webapp/js/main.js b/src/main/webapp/js/main.js new file mode 100644 index 0000000..31f59be --- /dev/null +++ b/src/main/webapp/js/main.js @@ -0,0 +1,27 @@ +$(document).ready(function () { + console.log("OK"); + + // $("#films").append(generateFilmCard("lorem", "lorem")); + + $.get("http://localhost:8080/api/film", function (data) { + console.table(data); + + for (let dataKey of data) { + $("#films").append(generateFilmCard(dataKey.name, dataKey.description)); + } + }); +}); + +function generateFilmCard(title, description) { + return `
+
+
${title}
+

${description}

+ +
+ Il y a 20 minutes + 1h20min +
+
+
`; +} \ No newline at end of file