Skip to content
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

Created a toggle function that allows users to switch between dark mode and light mode. #17

Merged
merged 11 commits into from
Feb 25, 2022

Conversation

Majd-sufian
Copy link
Contributor

@Majd-sufian Majd-sufian commented Feb 25, 2022

Created a toggle function that allows users to switch between dark mode and light mode.

The way it works:

  • Open piral browser extension.
  • Go to settings that located in the right corner of the page.
  • Search for (Switch to dark) or (Switch to light).
  • Click on the toggle button and the theme will automatically be switched.
  • After toggling the preference theme, it will be saved to local storage for future use.

@Majd-sufian Majd-sufian changed the title Develop Created a toggle function that allows users to switch between dark mode and light mode. Feb 25, 2022
@Majd-sufian Majd-sufian reopened this Feb 25, 2022
@Majd-sufian
Copy link
Contributor Author

Majd-sufian commented Feb 25, 2022

Created a toggle function that allows users to switch between dark mode and light mode.

The way it works:

  • Open piral browser extension.
  • Go to settings that located in the right corner of the page.
  • Search for (Switch to dark) or (Switch to light).
  • Click on the toggle button and the theme will automatically be switched.

@@ -3,6 +3,7 @@ import { Button, Modal, ModalHeader, ModalBody, ModalFooter, FormGroup, Label, I
import { jsx } from '@emotion/core';
import { emitEvent } from './commands';
import { checkJson } from './utils';
import { appSectionView } from './styles';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove unused import.

@@ -2,6 +2,7 @@ import { FC, ChangeEvent, useState } from 'react';
import { CustomInput, InputGroup, InputGroupAddon, Button } from 'reactstrap';
import { jsx } from '@emotion/core';
import { injectPiletsFromUrl } from './utils';
import { appSectionView } from './styles';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove unused import.

Copy link
Contributor

@FlorianRappl FlorianRappl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! Thanks 🍻

@FlorianRappl FlorianRappl merged commit b5ef15d into smapiot:develop Feb 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants