Skip to content

Add style #3

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 15 commits into
base: dev
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 12 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
"env": {
"browser": true,
"es6": true,
"jest": true
},
"parser": "babel-eslint",
"parserOptions": {
"ecmaVersion": 2018,
"sourceType": "module"
},
"extends": ["airbnb-base"],
"rules": {
"no-shadow": "off",
"no-param-reassign": "off",
"eol-last": "off",
"import/extensions": [ 1, {
"js": "always", "json": "always"
}]
},
"ignorePatterns": [
"dist/",
"build/"
]
}
70 changes: 70 additions & 0 deletions .github/workflows/linters.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
name: Linters

on: pull_request

env:
FORCE_COLOR: 1

jobs:
lighthouse:
name: Lighthouse
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: "12.x"
- name: Setup Lighthouse
run: npm install -g @lhci/cli@0.7.x
- name: Lighthouse Report
run: lhci autorun --upload.target=temporary-public-storage --collect.staticDistDir=.
webhint:
name: Webhint
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: "12.x"
- name: Setup Webhint
run: |
npm install --save-dev hint@7.x
[ -f .hintrc ] || wget https://raw.githubusercontent.com/microverseinc/linters-config/master/html-css-js/.hintrc
- name: Webhint Report
run: npx hint .
stylelint:
name: Stylelint
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: "12.x"
- name: Setup Stylelint
run: |
npm install --save-dev stylelint@13.x stylelint-scss@3.x stylelint-config-standard@21.x stylelint-csstree-validator@1.x
[ -f .stylelintrc.json ] || wget https://raw.githubusercontent.com/microverseinc/linters-config/master/html-css-js/.stylelintrc.json
- name: Stylelint Report
run: npx stylelint "**/*.{css,scss}"
eslint:
name: ESLint
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: "12.x"
- name: Setup ESLint
run: |
npm install --save-dev eslint@7.x eslint-config-airbnb-base@14.x eslint-plugin-import@2.x babel-eslint@10.x
[ -f .eslintrc.json ] || wget https://raw.githubusercontent.com/microverseinc/linters-config/master/html-css-js/.eslintrc.json
- name: ESLint Report
run: npx eslint .
nodechecker:
name: node_modules checker
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v2
- name: Check node_modules existence
run: |
if [ -d "node_modules/" ]; then echo -e "\e[1;31mThe node_modules/ folder was pushed to the repo. Please remove it from the GitHub repository and try again."; echo -e "\e[1;32mYou can set up a .gitignore file with this folder included on it to prevent this from happening in the future." && exit 1; fi
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# .gitignore
node_modules/
18 changes: 18 additions & 0 deletions .hintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"connector": {
"name": "local",
"options": {
"pattern": ["**", "!.git/**", "!node_modules/**"]
}
},
"extends": ["development"],
"formatters": ["stylish"],
"hints": [
"button-type",
"disown-opener",
"html-checker",
"meta-charset-utf-8",
"meta-viewport",
"no-inline-styles:error"
]
}
20 changes: 20 additions & 0 deletions .stylelintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"extends": ["stylelint-config-standard"],
"plugins": ["stylelint-scss", "stylelint-csstree-validator"],
"rules": {
"at-rule-no-unknown": [
true,
{
"ignoreAtRules": ["tailwind", "apply", "variants", "responsive", "screen"]
}
],
"scss/at-rule-no-unknown": [
true,
{
"ignoreAtRules": ["tailwind", "apply", "variants", "responsive", "screen"]
}
],
"csstree/validator": true
},
"ignoreFiles": ["build/**", "dist/**", "**/reset*.css", "**/bootstrap*.css", "**/*.js", "**/*.jsx"]
}
58 changes: 57 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,57 @@
# leaderboard
# leaderboard
>The leaderboard website displays scores submitted by different players. It also allows you to submit your score. All data is preserved thanks to the external Leaderboard API service.

## Built With

- HTML
- CSS
- Javascript

## Getting Started

To get a local copy up and running follow these simple steps.

### Prerequisites

- Use `git clone` to clone the repository using the HTTPS link into your local machine

### Setup

- `cd` into your local repository

### Install

- `npm install` - Installs the necessary dependencies

### Usage

- Open the index file and enjoy

### Deployment

- [Live Demo Link](https://zainab-alzubair.github.io/leaderboard/dist/)

## Authors

👤 **Zainab**

- GitHub: [@Zainab-Alzubair](https://github.com/Zainab-Alzubair)
- LinkedIn: [LinkedIn](https://www.linkedin.com/in/zainab-al-zubair-bb6777168/)

## 🤝 Contributing

Contributions, issues, and feature requests are welcome!

Feel free to check the [issues page](https://github.com/Zainab-Alzubair/leaderboard/issues).

## Show your support

Give a ⭐️ if you like this project!

## Acknowledgments

- [Microverse](https://www.microverse.org/)

## 📝 License

This project is [MIT](./LICENSE) licensed.
42 changes: 42 additions & 0 deletions dist/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Leaderboard</title>
<script defer src="runtime.js"></script><script defer src="main.js"></script></head>
<body>
<div class="header">
<img src="https://img.icons8.com/neon/96/null/experimental-trophy-neon.png"/>
<h1 class="headline">Leaderboard</h1>
<img src="https://img.icons8.com/neon/96/null/experimental-trophy-neon.png"/>
</div>
<div class="content-wrap">

<div class="left-coulmn">

<div class="head-content">
<h2 class="span">Recent scors</h2>
<div class="refresh-btn">Refresh</div>
</div>
<div class="table">
<h4 class="text table-row">Please click Refresh button to display data</h4>
</div>
</div>
<div class="right-coulmn">
<div class="right-content">

<h3>Add your score</h3>
<form id="form">
<input type="text" id="user" name="user" placeholder="Add your Name"><br>
<input type="integer" id="score" name="score" placeholder="your Score"><br><br>
<div class="error"></div>
<input type="submit" value="Submit" class="submit-btn">

</form>
</div>

</div>
</div>
</body>
</html>
Loading