-
Notifications
You must be signed in to change notification settings - Fork 43
added dark and light mode button #25
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
base: master
Are you sure you want to change the base?
Conversation
sakshee-19
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please fix some minor issues.
css/stylesheet.css
Outdated
| margin: 4px 2px; | ||
| cursor: pointer; | ||
| border-radius: 50%; | ||
| } No newline at end of file |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add EOF.
| let out = document.getElementById("out") | ||
| let flag=0 | ||
|
|
||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need to add empty lines.
js/main.js
Outdated
| } | ||
|
|
||
|
|
||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove extra unnecessary empty lines.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your reviews @sakshee-19
sakshee-19
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please squash your commits and provide a preview link to test the changes.
|
preview link : https://armish24.github.io/geolocation/ |
js/main.js
Outdated
| {document.body.style.background = 'black'; | ||
| document.getElementById("title").style.color = 'white'; | ||
| document.getElementById("myButton1").value="Light"; | ||
| document.getElementById("myButton1").style.background = 'white'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you intend this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I modified the code, to minimize size of code .Kindly have a look
| </head> | ||
| <body> | ||
| <h2>Geo locator to faciliate easy integration of location data</h2> | ||
| <input type="button" value="Dark" id="myButton1" onclick="changeBodyBg();"></input> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pls intend correctly
Add the feature of dark and light mode in main page.
SCREENSHOTS
LIGHT MODE :-
DARK MODE :-