diff --git a/passenger-counter/README.md b/passenger-counter/README.md new file mode 100644 index 0000000..d115155 --- /dev/null +++ b/passenger-counter/README.md @@ -0,0 +1,11 @@ +# App counter + +## About this project + +This is a passenger counter app which can be used to count people on a particular railway station. This project is made using HTML , CSS , and Javascript . +Its an iteresting app that you should check out . + +# To see the output [CLICK HERE](https://deeps65.github.io/passenger-counter/) + + +Happy Coding! diff --git a/passenger-counter/index.css b/passenger-counter/index.css new file mode 100644 index 0000000..b6a706c --- /dev/null +++ b/passenger-counter/index.css @@ -0,0 +1,38 @@ +body { + background-image: url("station.jpg"); + background-size: cover; + font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif; + font-weight: bold; + text-align: center; +} + +h1 { + margin-top: 10px; + margin-bottom: 10px; +} + +h2 { + font-size: 50px; + margin-top: 0; + margin-bottom: 20px; +} + +button { + border: none; + padding-top: 10px; + padding-bottom: 10px; + color: white; + font-weight: bold; + width: 200px; + margin-bottom: 5px; + border-radius: 5px; +} + +#increment-btn { + background: darkred; +} + +#save-btn { + background: darkgreen; +} + diff --git a/passenger-counter/index.html b/passenger-counter/index.html new file mode 100644 index 0000000..917cc31 --- /dev/null +++ b/passenger-counter/index.html @@ -0,0 +1,15 @@ + +
+ + + +Previous entries:
+ + + \ No newline at end of file diff --git a/passenger-counter/index.js b/passenger-counter/index.js new file mode 100644 index 0000000..e8f06fe --- /dev/null +++ b/passenger-counter/index.js @@ -0,0 +1,15 @@ +let saveEl = document.getElementById("save-el") +let countEl = document.getElementById("count-el") +let count = 0 + +function increment() { + count += 1 + countEl.textContent = count +} + +function save() { + let countStr = count + " - " + saveEl.textContent += countStr + countEl.textContent = 0 + count = 0 +} diff --git a/passenger-counter/station.jpg b/passenger-counter/station.jpg new file mode 100644 index 0000000..53fac69 Binary files /dev/null and b/passenger-counter/station.jpg differ diff --git a/passenger-counter/yarn.jpeg b/passenger-counter/yarn.jpeg new file mode 100644 index 0000000..24c55be Binary files /dev/null and b/passenger-counter/yarn.jpeg differ