Repository: Textualize/textual

Issue:
Alternative method to initialise `Select`
I propose we extend `Select.__init__` or create a classmethod `Select.from_values` to accept an iterable of `SelectType` and automatically build the labels by converting them to strings.

I find that often we just want labels that are string representations of the values we want to select:

```py
Select.from_values(data_source)
# vs
Select([(str(datum), datum) for datum in data_source])
```

`data_source` is often just a list of strings or paths and the comprehension to create the tuple looks really awkward.

For example, in the `Select` docs we do this:

```py
# ...
yield Select((line, line) for line in LINES)
```

I personally don't like it at all.


Discussion:
Can I work on this?

I have done a quick prototype solution following the class method approach you suggested.  Before I go forward with formalizing the prototype, I wanted to ask: is this preferrable to overloading the constructor?
Hey @azinneck0485 thanks for your interest!
I don't see any particular reason why you wouldn't be able to work on this. 🤷 

Let us just make sure that the class method is a good idea and then we'll let you know.
If you're working on this, make sure to read the [contributing guidelines](https://github.com/Textualize/textual/blob/main/CONTRIBUTING.md) for an experience as smooth as possible!

Resolving patch:
diff --git a/docs/examples/widgets/select_from_values_widget.py b/docs/examples/widgets/select_from_values_widget.py
new file mode 100644
--- /dev/null
+++ b/docs/examples/widgets/select_from_values_widget.py
@@ -0,0 +1,26 @@
+from textual import on
+from textual.app import App, ComposeResult
+from textual.widgets import Header, Select
+
+LINES = """I must not fear.
+Fear is the mind-killer.
+Fear is the little-death that brings total obliteration.
+I will face my fear.
+I will permit it to pass over me and through me.""".splitlines()
+
+
+class SelectApp(App):
+    CSS_PATH = "select.tcss"
+
+    def compose(self) -> ComposeResult:
+        yield Header()
+        yield Select.from_values(LINES)
+
+    @on(Select.Changed)
+    def select_changed(self, event: Select.Changed) -> None:
+        self.title = str(event.value)
+
+
+if __name__ == "__main__":
+    app = SelectApp()
+    app.run()
diff --git a/src/textual/widgets/_select.py b/src/textual/widgets/_select.py
--- a/src/textual/widgets/_select.py
+++ b/src/textual/widgets/_select.py
@@ -284,7 +284,7 @@ def __init__(
         Args:
             options: Options to select from. If no options are provided then
                 `allow_blank` must be set to `True`.
-            prompt: Text to show in the control when no option is select.
+            prompt: Text to show in the control when no option is selected.
             allow_blank: Enables or disables the ability to have the widget in a state
                 with no selection made, in which case its value is set to the constant
                 [`Select.BLANK`][textual.widgets.Select.BLANK].
@@ -292,7 +292,7 @@ def __init__(
                 If no initial value is set and `allow_blank` is `False`, the widget
                 will auto-select the first available option.
             name: The name of the select control.
-            id: The ID of the control the DOM.
+            id: The ID of the control in the DOM.
             classes: The CSS classes of the control.
             disabled: Whether the control is disabled or not.
 
@@ -305,6 +305,54 @@ def __init__(
         self._value = value
         self._setup_variables_for_options(options)
 
+    @classmethod
+    def from_values(
+        cls,
+        values: Iterable[SelectType],
+        *,
+        prompt: str = "Select",
+        allow_blank: bool = True,
+        value: SelectType | NoSelection = BLANK,
+        name: str | None = None,
+        id: str | None = None,
+        classes: str | None = None,
+        disabled: bool = False,
+    ) -> Select[SelectType]:
+        """Initialize the Select control with values specified by an arbitrary iterable
+
+        The options shown in the control are computed by calling the built-in `str`
+        on each value.
+
+        Args:
+            values: Values used to generate options to select from.
+            prompt: Text to show in the control when no option is selected.
+            allow_blank: Enables or disables the ability to have the widget in a state
+                with no selection made, in which case its value is set to the constant
+                [`Select.BLANK`][textual.widgets.Select.BLANK].
+            value: Initial value selected. Should be one of the values in `values`.
+                If no initial value is set and `allow_blank` is `False`, the widget
+                will auto-select the first available value.
+            name: The name of the select control.
+            id: The ID of the control in the DOM.
+            classes: The CSS classes of the control.
+            disabled: Whether the control is disabled or not.
+
+        Returns:
+            A new Select widget with the provided values as options.
+        """
+        options_iterator = [(str(value), value) for value in values]
+
+        return cls(
+            options_iterator,
+            prompt=prompt,
+            allow_blank=allow_blank,
+            value=value,
+            name=name,
+            id=id,
+            classes=classes,
+            disabled=disabled,
+        )
+
     def _setup_variables_for_options(
         self,
         options: Iterable[tuple[RenderableType, SelectType]],


Test patch:
diff --git a/tests/snapshot_tests/__snapshots__/test_snapshots.ambr b/tests/snapshot_tests/__snapshots__/test_snapshots.ambr
--- a/tests/snapshot_tests/__snapshots__/test_snapshots.ambr
+++ b/tests/snapshot_tests/__snapshots__/test_snapshots.ambr
@@ -29349,6 +29349,170 @@
   
   '''
 # ---
+# name: test_select_from_values_expanded
+  '''
+  <svg class="rich-terminal" viewBox="0 0 994 635.5999999999999" xmlns="http://www.w3.org/2000/svg">
+      <!-- Generated with Rich https://www.textualize.io -->
+      <style>
+  
+      @font-face {
+          font-family: "Fira Code";
+          src: local("FiraCode-Regular"),
+                  url("https://cdnjs.cloudflare.com/ajax/libs/firacode/6.2.0/woff2/FiraCode-Regular.woff2") format("woff2"),
+                  url("https://cdnjs.cloudflare.com/ajax/libs/firacode/6.2.0/woff/FiraCode-Regular.woff") format("woff");
+          font-style: normal;
+          font-weight: 400;
+      }
+      @font-face {
+          font-family: "Fira Code";
+          src: local("FiraCode-Bold"),
+                  url("https://cdnjs.cloudflare.com/ajax/libs/firacode/6.2.0/woff2/FiraCode-Bold.woff2") format("woff2"),
+                  url("https://cdnjs.cloudflare.com/ajax/libs/firacode/6.2.0/woff/FiraCode-Bold.woff") format("woff");
+          font-style: bold;
+          font-weight: 700;
+      }
+  
+      .terminal-2035490498-matrix {
+          font-family: Fira Code, monospace;
+          font-size: 20px;
+          line-height: 24.4px;
+          font-variant-east-asian: full-width;
+      }
+  
+      .terminal-2035490498-title {
+          font-size: 18px;
+          font-weight: bold;
+          font-family: arial;
+      }
+  
+      .terminal-2035490498-r1 { fill: #c5c8c6 }
+  .terminal-2035490498-r2 { fill: #e3e3e3 }
+  .terminal-2035490498-r3 { fill: #e1e1e1 }
+  .terminal-2035490498-r4 { fill: #1e1e1e }
+  .terminal-2035490498-r5 { fill: #0178d4 }
+  .terminal-2035490498-r6 { fill: #787878 }
+  .terminal-2035490498-r7 { fill: #a8a8a8 }
+  .terminal-2035490498-r8 { fill: #121212 }
+  .terminal-2035490498-r9 { fill: #ddedf9;font-weight: bold }
+  .terminal-2035490498-r10 { fill: #85beea;font-weight: bold }
+  .terminal-2035490498-r11 { fill: #e2e3e3 }
+      </style>
+  
+      <defs>
+      <clipPath id="terminal-2035490498-clip-terminal">
+        <rect x="0" y="0" width="975.0" height="584.5999999999999" />
+      </clipPath>
+      <clipPath id="terminal-2035490498-line-0">
+      <rect x="0" y="1.5" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-1">
+      <rect x="0" y="25.9" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-2">
+      <rect x="0" y="50.3" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-3">
+      <rect x="0" y="74.7" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-4">
+      <rect x="0" y="99.1" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-5">
+      <rect x="0" y="123.5" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-6">
+      <rect x="0" y="147.9" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-7">
+      <rect x="0" y="172.3" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-8">
+      <rect x="0" y="196.7" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-9">
+      <rect x="0" y="221.1" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-10">
+      <rect x="0" y="245.5" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-11">
+      <rect x="0" y="269.9" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-12">
+      <rect x="0" y="294.3" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-13">
+      <rect x="0" y="318.7" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-14">
+      <rect x="0" y="343.1" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-15">
+      <rect x="0" y="367.5" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-16">
+      <rect x="0" y="391.9" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-17">
+      <rect x="0" y="416.3" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-18">
+      <rect x="0" y="440.7" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-19">
+      <rect x="0" y="465.1" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-20">
+      <rect x="0" y="489.5" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-21">
+      <rect x="0" y="513.9" width="976" height="24.65"/>
+              </clipPath>
+  <clipPath id="terminal-2035490498-line-22">
+      <rect x="0" y="538.3" width="976" height="24.65"/>
+              </clipPath>
+      </defs>
+  
+      <rect fill="#292929" stroke="rgba(255,255,255,0.35)" stroke-width="1" x="1" y="1" width="992" height="633.6" rx="8"/><text class="terminal-2035490498-title" fill="#c5c8c6" text-anchor="middle" x="496" y="27">SelectApp</text>
+              <g transform="translate(26,22)">
+              <circle cx="0" cy="0" r="7" fill="#ff5f57"/>
+              <circle cx="22" cy="0" r="7" fill="#febc2e"/>
+              <circle cx="44" cy="0" r="7" fill="#28c840"/>
+              </g>
+          
+      <g transform="translate(9, 41)" clip-path="url(#terminal-2035490498-clip-terminal)">
+      <rect fill="#282828" x="0" y="1.5" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#282828" x="12.2" y="1.5" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#282828" x="24.4" y="1.5" width="61" height="24.65" shape-rendering="crispEdges"/><rect fill="#282828" x="85.4" y="1.5" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#282828" x="97.6" y="1.5" width="317.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#282828" x="414.8" y="1.5" width="109.8" height="24.65" shape-rendering="crispEdges"/><rect fill="#282828" x="524.6" y="1.5" width="329.4" height="24.65" shape-rendering="crispEdges"/><rect fill="#282828" x="854" y="1.5" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#282828" x="866.2" y="1.5" width="0" height="24.65" shape-rendering="crispEdges"/><rect fill="#282828" x="866.2" y="1.5" width="97.6" height="24.65" shape-rendering="crispEdges"/><rect fill="#282828" x="963.8" y="1.5" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="25.9" width="976" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="50.3" width="976" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="74.7" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#0178d4" x="122" y="74.7" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#262626" x="134.2" y="74.7" width="707.6" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="841.8" y="74.7" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="854" y="74.7" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="99.1" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#0178d4" x="122" y="99.1" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#262626" x="134.2" y="99.1" width="24.4" height="24.65" shape-rendering="crispEdges"/><rect fill="#262626" x="158.6" y="99.1" width="73.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#262626" x="231.8" y="99.1" width="561.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#262626" x="793" y="99.1" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#262626" x="805.2" y="99.1" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#262626" x="817.4" y="99.1" width="24.4" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="841.8" y="99.1" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="854" y="99.1" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="123.5" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#0178d4" x="122" y="123.5" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#262626" x="134.2" y="123.5" width="707.6" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="841.8" y="123.5" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="854" y="123.5" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="147.9" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#121212" x="122" y="147.9" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="134.2" y="147.9" width="707.6" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="841.8" y="147.9" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="854" y="147.9" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="172.3" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#121212" x="122" y="172.3" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="134.2" y="172.3" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#0178d4" x="146.4" y="172.3" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#0178d4" x="158.6" y="172.3" width="73.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#0178d4" x="231.8" y="172.3" width="585.6" height="24.65" shape-rendering="crispEdges"/><rect fill="#0178d4" x="817.4" y="172.3" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="829.6" y="172.3" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="841.8" y="172.3" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="854" y="172.3" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="196.7" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#121212" x="122" y="196.7" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="134.2" y="196.7" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="146.4" y="196.7" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="158.6" y="196.7" width="195.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="353.8" y="196.7" width="463.6" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="817.4" y="196.7" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="829.6" y="196.7" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="841.8" y="196.7" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="854" y="196.7" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="221.1" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#121212" x="122" y="221.1" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="134.2" y="221.1" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="146.4" y="221.1" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="158.6" y="221.1" width="292.8" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="451.4" y="221.1" width="366" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="817.4" y="221.1" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="829.6" y="221.1" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="841.8" y="221.1" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="854" y="221.1" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="245.5" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#121212" x="122" y="245.5" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="134.2" y="245.5" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="146.4" y="245.5" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="158.6" y="245.5" width="524.6" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="683.2" y="245.5" width="134.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="817.4" y="245.5" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="829.6" y="245.5" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="841.8" y="245.5" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="854" y="245.5" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="269.9" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#121212" x="122" y="269.9" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="134.2" y="269.9" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="146.4" y="269.9" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="158.6" y="269.9" width="158.6" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="317.2" y="269.9" width="500.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="817.4" y="269.9" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="829.6" y="269.9" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="841.8" y="269.9" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="854" y="269.9" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="294.3" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#121212" x="122" y="294.3" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="134.2" y="294.3" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="146.4" y="294.3" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="158.6" y="294.3" width="244" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="402.6" y="294.3" width="414.8" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="817.4" y="294.3" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="829.6" y="294.3" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="841.8" y="294.3" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="854" y="294.3" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="318.7" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#121212" x="122" y="318.7" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="134.2" y="318.7" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="146.4" y="318.7" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="158.6" y="318.7" width="585.6" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="744.2" y="318.7" width="73.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="817.4" y="318.7" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="829.6" y="318.7" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="841.8" y="318.7" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="854" y="318.7" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="343.1" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#121212" x="122" y="343.1" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#24292f" x="134.2" y="343.1" width="707.6" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="841.8" y="343.1" width="12.2" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="854" y="343.1" width="122" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="367.5" width="976" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="391.9" width="976" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="416.3" width="976" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="440.7" width="976" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="465.1" width="976" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="489.5" width="976" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="513.9" width="976" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="538.3" width="976" height="24.65" shape-rendering="crispEdges"/><rect fill="#1e1e1e" x="0" y="562.7" width="976" height="24.65" shape-rendering="crispEdges"/>
+      <g class="terminal-2035490498-matrix">
+      <text class="terminal-2035490498-r2" x="12.2" y="20" textLength="12.2" clip-path="url(#terminal-2035490498-line-0)">⭘</text><text class="terminal-2035490498-r2" x="414.8" y="20" textLength="109.8" clip-path="url(#terminal-2035490498-line-0)">SelectApp</text><text class="terminal-2035490498-r1" x="976" y="20" textLength="12.2" clip-path="url(#terminal-2035490498-line-0)">
+  </text><text class="terminal-2035490498-r1" x="976" y="44.4" textLength="12.2" clip-path="url(#terminal-2035490498-line-1)">
+  </text><text class="terminal-2035490498-r1" x="976" y="68.8" textLength="12.2" clip-path="url(#terminal-2035490498-line-2)">
+  </text><text class="terminal-2035490498-r4" x="122" y="93.2" textLength="12.2" clip-path="url(#terminal-2035490498-line-3)">▊</text><text class="terminal-2035490498-r5" x="134.2" y="93.2" textLength="707.6" clip-path="url(#terminal-2035490498-line-3)">▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔</text><text class="terminal-2035490498-r5" x="841.8" y="93.2" textLength="12.2" clip-path="url(#terminal-2035490498-line-3)">▎</text><text class="terminal-2035490498-r1" x="976" y="93.2" textLength="12.2" clip-path="url(#terminal-2035490498-line-3)">
+  </text><text class="terminal-2035490498-r4" x="122" y="117.6" textLength="12.2" clip-path="url(#terminal-2035490498-line-4)">▊</text><text class="terminal-2035490498-r6" x="158.6" y="117.6" textLength="73.2" clip-path="url(#terminal-2035490498-line-4)">Select</text><text class="terminal-2035490498-r7" x="805.2" y="117.6" textLength="12.2" clip-path="url(#terminal-2035490498-line-4)">▲</text><text class="terminal-2035490498-r5" x="841.8" y="117.6" textLength="12.2" clip-path="url(#terminal-2035490498-line-4)">▎</text><text class="terminal-2035490498-r1" x="976" y="117.6" textLength="12.2" clip-path="url(#terminal-2035490498-line-4)">
+  </text><text class="terminal-2035490498-r4" x="122" y="142" textLength="12.2" clip-path="url(#terminal-2035490498-line-5)">▊</text><text class="terminal-2035490498-r5" x="134.2" y="142" textLength="707.6" clip-path="url(#terminal-2035490498-line-5)">▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁</text><text class="terminal-2035490498-r5" x="841.8" y="142" textLength="12.2" clip-path="url(#terminal-2035490498-line-5)">▎</text><text class="terminal-2035490498-r1" x="976" y="142" textLength="12.2" clip-path="url(#terminal-2035490498-line-5)">
+  </text><text class="terminal-2035490498-r4" x="122" y="166.4" textLength="12.2" clip-path="url(#terminal-2035490498-line-6)">▊</text><text class="terminal-2035490498-r8" x="134.2" y="166.4" textLength="707.6" clip-path="url(#terminal-2035490498-line-6)">▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔</text><text class="terminal-2035490498-r8" x="841.8" y="166.4" textLength="12.2" clip-path="url(#terminal-2035490498-line-6)">▎</text><text class="terminal-2035490498-r1" x="976" y="166.4" textLength="12.2" clip-path="url(#terminal-2035490498-line-6)">
+  </text><text class="terminal-2035490498-r4" x="122" y="190.8" textLength="12.2" clip-path="url(#terminal-2035490498-line-7)">▊</text><text class="terminal-2035490498-r10" x="158.6" y="190.8" textLength="73.2" clip-path="url(#terminal-2035490498-line-7)">Select</text><text class="terminal-2035490498-r8" x="841.8" y="190.8" textLength="12.2" clip-path="url(#terminal-2035490498-line-7)">▎</text><text class="terminal-2035490498-r1" x="976" y="190.8" textLength="12.2" clip-path="url(#terminal-2035490498-line-7)">
+  </text><text class="terminal-2035490498-r4" x="122" y="215.2" textLength="12.2" clip-path="url(#terminal-2035490498-line-8)">▊</text><text class="terminal-2035490498-r11" x="158.6" y="215.2" textLength="195.2" clip-path="url(#terminal-2035490498-line-8)">I&#160;must&#160;not&#160;fear.</text><text class="terminal-2035490498-r8" x="841.8" y="215.2" textLength="12.2" clip-path="url(#terminal-2035490498-line-8)">▎</text><text class="terminal-2035490498-r1" x="976" y="215.2" textLength="12.2" clip-path="url(#terminal-2035490498-line-8)">
+  </text><text class="terminal-2035490498-r4" x="122" y="239.6" textLength="12.2" clip-path="url(#terminal-2035490498-line-9)">▊</text><text class="terminal-2035490498-r11" x="158.6" y="239.6" textLength="292.8" clip-path="url(#terminal-2035490498-line-9)">Fear&#160;is&#160;the&#160;mind-killer.</text><text class="terminal-2035490498-r8" x="841.8" y="239.6" textLength="12.2" clip-path="url(#terminal-2035490498-line-9)">▎</text><text class="terminal-2035490498-r1" x="976" y="239.6" textLength="12.2" clip-path="url(#terminal-2035490498-line-9)">
+  </text><text class="terminal-2035490498-r4" x="122" y="264" textLength="12.2" clip-path="url(#terminal-2035490498-line-10)">▊</text><text class="terminal-2035490498-r11" x="158.6" y="264" textLength="524.6" clip-path="url(#terminal-2035490498-line-10)">Fear&#160;is&#160;the&#160;little-death&#160;that&#160;brings&#160;total&#160;</text><text class="terminal-2035490498-r8" x="841.8" y="264" textLength="12.2" clip-path="url(#terminal-2035490498-line-10)">▎</text><text class="terminal-2035490498-r1" x="976" y="264" textLength="12.2" clip-path="url(#terminal-2035490498-line-10)">
+  </text><text class="terminal-2035490498-r4" x="122" y="288.4" textLength="12.2" clip-path="url(#terminal-2035490498-line-11)">▊</text><text class="terminal-2035490498-r11" x="158.6" y="288.4" textLength="158.6" clip-path="url(#terminal-2035490498-line-11)">obliteration.</text><text class="terminal-2035490498-r8" x="841.8" y="288.4" textLength="12.2" clip-path="url(#terminal-2035490498-line-11)">▎</text><text class="terminal-2035490498-r1" x="976" y="288.4" textLength="12.2" clip-path="url(#terminal-2035490498-line-11)">
+  </text><text class="terminal-2035490498-r4" x="122" y="312.8" textLength="12.2" clip-path="url(#terminal-2035490498-line-12)">▊</text><text class="terminal-2035490498-r11" x="158.6" y="312.8" textLength="244" clip-path="url(#terminal-2035490498-line-12)">I&#160;will&#160;face&#160;my&#160;fear.</text><text class="terminal-2035490498-r8" x="841.8" y="312.8" textLength="12.2" clip-path="url(#terminal-2035490498-line-12)">▎</text><text class="terminal-2035490498-r1" x="976" y="312.8" textLength="12.2" clip-path="url(#terminal-2035490498-line-12)">
+  </text><text class="terminal-2035490498-r4" x="122" y="337.2" textLength="12.2" clip-path="url(#terminal-2035490498-line-13)">▊</text><text class="terminal-2035490498-r11" x="158.6" y="337.2" textLength="585.6" clip-path="url(#terminal-2035490498-line-13)">I&#160;will&#160;permit&#160;it&#160;to&#160;pass&#160;over&#160;me&#160;and&#160;through&#160;me.</text><text class="terminal-2035490498-r8" x="841.8" y="337.2" textLength="12.2" clip-path="url(#terminal-2035490498-line-13)">▎</text><text class="terminal-2035490498-r1" x="976" y="337.2" textLength="12.2" clip-path="url(#terminal-2035490498-line-13)">
+  </text><text class="terminal-2035490498-r4" x="122" y="361.6" textLength="12.2" clip-path="url(#terminal-2035490498-line-14)">▊</text><text class="terminal-2035490498-r8" x="134.2" y="361.6" textLength="707.6" clip-path="url(#terminal-2035490498-line-14)">▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁</text><text class="terminal-2035490498-r8" x="841.8" y="361.6" textLength="12.2" clip-path="url(#terminal-2035490498-line-14)">▎</text><text class="terminal-2035490498-r1" x="976" y="361.6" textLength="12.2" clip-path="url(#terminal-2035490498-line-14)">
+  </text><text class="terminal-2035490498-r1" x="976" y="386" textLength="12.2" clip-path="url(#terminal-2035490498-line-15)">
+  </text><text class="terminal-2035490498-r1" x="976" y="410.4" textLength="12.2" clip-path="url(#terminal-2035490498-line-16)">
+  </text><text class="terminal-2035490498-r1" x="976" y="434.8" textLength="12.2" clip-path="url(#terminal-2035490498-line-17)">
+  </text><text class="terminal-2035490498-r1" x="976" y="459.2" textLength="12.2" clip-path="url(#terminal-2035490498-line-18)">
+  </text><text class="terminal-2035490498-r1" x="976" y="483.6" textLength="12.2" clip-path="url(#terminal-2035490498-line-19)">
+  </text><text class="terminal-2035490498-r1" x="976" y="508" textLength="12.2" clip-path="url(#terminal-2035490498-line-20)">
+  </text><text class="terminal-2035490498-r1" x="976" y="532.4" textLength="12.2" clip-path="url(#terminal-2035490498-line-21)">
+  </text><text class="terminal-2035490498-r1" x="976" y="556.8" textLength="12.2" clip-path="url(#terminal-2035490498-line-22)">
+  </text>
+      </g>
+      </g>
+  </svg>
+  
+  '''
+# ---
 # name: test_select_no_blank_has_default_value
   '''
   <svg class="rich-terminal" viewBox="0 0 994 635.5999999999999" xmlns="http://www.w3.org/2000/svg">
diff --git a/tests/snapshot_tests/test_snapshots.py b/tests/snapshot_tests/test_snapshots.py
--- a/tests/snapshot_tests/test_snapshots.py
+++ b/tests/snapshot_tests/test_snapshots.py
@@ -351,6 +351,12 @@ def test_select_expanded(snap_compare):
     )
 
 
+def test_select_from_values_expanded(snap_compare):
+    assert snap_compare(
+        WIDGET_EXAMPLES_DIR / "select_from_values_widget.py", press=["tab", "enter"]
+    )
+
+
 def test_select_expanded_changed(snap_compare):
     assert snap_compare(
         WIDGET_EXAMPLES_DIR / "select_widget.py",