MCPcopy Index your code
hub / github.com/archlinux/archinstall / InputScreen

Class InputScreen

archinstall/tui/components.py:781–900  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

779
780
781class InputScreen(BaseScreen[str]):
782 CSS = """
783 InputScreen {
784 align: center middle;
785 }
786
787 .container-wrapper {
788 align: center top;
789 width: 100%;
790 height: 1fr;
791 }
792
793 .input-content {
794 width: 60;
795 height: 10;
796 }
797
798 .input-failure {
799 color: red;
800 text-align: center;
801 }
802
803 #input-info {
804 text-align: center;
805 }
806
807 .input-hint-msg-error {
808 color: red;
809 }
810
811 .input-hint-msg-warning {
812 color: yellow;
813 }
814
815 .input-hint-msg-info {
816 color: green;
817 }
818 """
819
820 def __init__(
821 self,
822 header: str | None = None,
823 placeholder: str | None = None,
824 password: bool = False,
825 default_value: str | None = None,
826 allow_reset: bool = False,
827 allow_skip: bool = False,
828 validator: Validator | None = None,
829 info_callback: Callable[[str], InputInfo | None] | None = None,
830 ):
831 super().__init__(allow_skip, allow_reset)
832 self._header = header or ''
833 self._placeholder = placeholder or ''
834 self._password = password
835 self._default_value = default_value or ''
836 self._allow_reset = allow_reset
837 self._allow_skip = allow_skip
838 self._validator = validator

Callers 2

_prompt_pskMethod · 0.90
showMethod · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected