Skip to content
This repository has been archived by the owner on Jan 14, 2022. It is now read-only.

enter language as text input #46

Open
arcturus140 opened this issue Feb 20, 2019 · 4 comments
Open

enter language as text input #46

arcturus140 opened this issue Feb 20, 2019 · 4 comments
Labels
Feature request User requests for new feature

Comments

@arcturus140
Copy link
Contributor

arcturus140 commented Feb 20, 2019

Snippet language can be chosen when clicking with the cursor in the selection box. Would be nice if it accepts text input directly, as well.

Steps to replicate

  1. Create -> Single-file snippet
  2. type "name" for snippet name -> press tap to next input field
  3. type "Brainfuck" -> press tap
  4. type "tag" -> press tap, press tap
  5. press tap
  6. press tap
  7. press "Create" button -> Error message appears: "Please specify at least snippet name and language"
  8. click into "Snippet language" input field
  9. press "Create" button -> success
@ZeroX-DG ZeroX-DG added the Feature request User requests for new feature label Feb 21, 2019
@bantya
Copy link
Contributor

bantya commented Feb 22, 2019

@arcturus140 I was about to report this issue and you did it!

Demonstration:

2019-02-23_01-05-17

@bantya
Copy link
Contributor

bantya commented Feb 22, 2019

Ideally, there should be no Snippet language drop-down for single file snippet.

Instead there should be a Snippet filename input to enter the filename for the snippet (same as Multi file Snippet 👇) along with the Snippet name input.

image

The Snippet name should be required to identify the snippet from the snippets list (current behavior).

The Snippet language should be guessed according to the file extension provided in Snippet filename. This will help mitigate the aforementioned issue.

e.g.

[Snippet name]:        [A test md file]
[Snippet language]:    [Markdown 🔽]

[Snippet name]:        [A test md file]
[Snippet filename]:    [test-file.md]

@bantya
Copy link
Contributor

bantya commented Feb 22, 2019

The Snippet filename can then be used to export the snippet content (just content w/o metadata) to a file with provided filename.

@ZeroX-DG
Copy link
Owner

ZeroX-DG commented Mar 4, 2019

Snippet filename is a good idea, I'll do it.....when I have the time 😢 so many things to do at uni.

@arcturus140 arcturus140 changed the title Cannot enter language as text input enter language as text input Mar 5, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Feature request User requests for new feature
Projects
None yet
Development

No branches or pull requests

3 participants