Git Product home page Git Product logo

itsprompt's People

Contributors

andrewthetechie avatar theitsnameless avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

itsprompt's Issues

[FEATURE] Add a real documentation

Feature description
Currently the whole project is documented in the README, which might get too cluttered if we add even more features. A separate documentation could be more easy to use.

[FEATURE] Add a search bar for select and checkbox

Feature description
Select and checkbox support big options list, and finding the one you need is hard. So with a search box, this would be easier.

Additional Information
Maybe add an optional key binding for opening a search box, and for every character hide the options that do not match the search.

[FEATURE] Add support for PyInquirers Seperator

Feature description
PyInquirer supports adding Seperators in some list types. These are small labels which are not selectable, but give more context to the user.

Additional Information
The prompts to include those labels are:

  • checkbox
  • expand
  • select
  • raw_select

[FEATURE] Add file_path prompt

Feature description
With a file_path prompt, the user may write a file path and it will be autocompleted based on the files on their device.

Additional Information
This should include an autocompleter, like the one prompt_toolkit gives us.

[FEATURE] Add more styling options

Feature description
It would be great to have more default styling options to choose from.

Another great feature is an option to change the design of some message components, e.g. the checkboxes, the numbers and the selection arrows.

[FEATURE] Add an autocompleter to the input prompt

Feature description
The autocompleter should be able to give the user a few options to select from.

Additional Information
This may either be done through prompt_tookit or through a separate function.

[FEATURE] add validator to TablePrompt

Feature description
It should be possible to add a validation function to the TablePrompt, in order to check whether the values filled in are all correct.

Additional Information
The function should take a pandas.DataFrame and return an error message, just like the InputPrompt.

[FEATURE] Add testing

Feature description
The project currently does not have any tests. They should be added.

[FEATURE] Add data type support to TablePrompt

Feature description
Currently, TablePrompt converts all input values to strings, but a way to support other types would be preferred.

Additional Information
Since we cannot know what type the user tries to input, there should be a way to tell TablePrompt the type a specific cell should be.

lambda validation hangs in v1.5 (build df965c6)

Describe the bug
This script from example.py works with v1.4 but fails in v1.5 (build df965c6)

import ItsPrompt
from ItsPrompt.prompt import Prompt 

# standard input with simple lambda validation
ans = Prompt.input(
    'Please type your id',
    validate=lambda x: "test" in x,
)
print(ans)

To Reproduce
Steps to reproduce the behavior:

  1. At prompt:
  2. [?] 'Please type your id',
  3. See error: Typing and pressing has no effect, the script is locked.

Expected behavior
Input should be able to be completed when pressing .

Device:

  • Windows 10 AMD64 (build 10.0.19045) SP0
  • Python 3.12.2, ItsPrompt version 1.5

[FEATURE] use `TablePrompt` with lists

Feature description
TablePrompt is currently able to use dict, where the keys are the column names. But since ItsPrompt is a tool which should be as easy to use as possible, the implementation of a list support would be great.

Additional Information
If a list is given to TablePrompt, the column names should start from "0" and go up, like pandas.DataFrame does when there are no column names given.

[FEATURE] Add options to TablePrompt

Feature description
Currently, TablePrompt is very basic. Features like marking a cell as immutable are missing.

Additional Information
It should be possible to create cells either by inputing a string (which will be the cell content) or a dictionary (may be an object as well) which has the attributes:

  • content
  • immutable
  • type

If only a string is used, it will be assumed as not immutable and the type will be string.

An example:

{"colum 1": [{"content": "this stays as is", "immutable": True}, "type here"]}

[FEATURE] Use TablePrompt without pandas

Feature description
Some users pointed out that making TablePrompt dependant on pandas will force them to install this huge library even in smaller projects.

Additional Information
It may be possible to create a version of TablePrompt which uses dictionaries instead of DataFrames.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.