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

Default language #101

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Conversation

deeheem
Copy link
Contributor

@deeheem deeheem commented Mar 11, 2018

Fixes issue:

#78

Changes:

A 'Set Default Language' option is added under the Setting icon which appears on the top right of the page as shown:

image

The modal shows a list of all extensions present, with their corresponding number of codes present in brackets. The list is saved in extensions/extensions.txt, which can easily be generated at the developers end by using a script or PowerShell commands.

The user can enable/disable the settings using the toggle switch on the top right of the model.

UI with disabled settings:
image

After enabling, the user can set his/her default languages(s).

If the results for a topic don't contain any code from any of the user's default languages, then codes with all extensions present are shown. For example, if the user has set his default languages as .cpp and .py, and the topic 'Fuzzy Search' only has codes available in .js and .php, then these 2 codes are shown instead of showing blank.

Also, please note that the settings are applicable after the user refreshes the page.

@AdiChat
Copy link
Member

AdiChat commented Mar 25, 2018

This feature is not working as expected.

The issue as depicted from the console is Synchronous XMLHttpRequest on the main thread is deprecated because of its detrimental effects to the end user's experience. For more help, check https://xhr.spec.whatwg.org/. This is related to the request to the extensions.txt file.

Kindly take a look into it. 👍

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.

None yet

2 participants