vue-termui icon indicating copy to clipboard operation
vue-termui copied to clipboard

feat: `Select` component

Open webfansplz opened this issue 2 years ago • 2 comments

https://user-images.githubusercontent.com/22515951/199018536-a9011662-7577-43e2-91a4-bf381b7fe242.mov

<template borderStyle="round">
  <Select v-model="value" @submit="submit">
    <Option :value="item.value" v-for="(item, index) in options" :key="index">
      <template v-slot="{ isActive }">
        <Box flexDirection="column">
          <Text :dimmed="isActive" :underline="isActive">{{ item.label }}</Text>
        </Box>
      </template>
    </Option>
  </Select>
</template>

webfansplz avatar Oct 31 '22 13:10 webfansplz

Deploy Preview for vue-termui ready!

Name Link
Latest commit d111cb6e75ec5ef9a2df2884314bc86ec4a57f0f
Latest deploy log https://app.netlify.com/sites/vue-termui/deploys/635fcd5ec6311b000946d145
Deploy Preview https://deploy-preview-18--vue-termui.netlify.app
Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

netlify[bot] avatar Oct 31 '22 13:10 netlify[bot]

I wonder if this should be really different: like the input component, it does look a lot like the prompts version but it could be so much more. I wonder if by having relative + absolute positioned boxes we could recreate the select menu that exists on the browser and cycle through them with tab (using the useFocusable()) we could also have both versions but I don't think we should have the submit event for example, that should be handled at a higher level

I think I need to write one of these to better explain what I mean by something really interactive. I will try to give the select a try and open a new PR if you want?

Sure,It's nice to see the PR.

webfansplz avatar Nov 02 '22 02:11 webfansplz