fix: width, auto grow and horizontal scroll on envinput

This commit is contained in:
liyasthomas
2022-02-11 11:18:43 +05:30
parent 698ebe1063
commit 1264511113
2 changed files with 8 additions and 18 deletions

View File

@@ -2,7 +2,9 @@
<div
class="sticky top-0 z-10 flex flex-shrink-0 p-4 space-x-2 overflow-x-auto bg-primary hide-scrollbar"
>
<div class="flex flex-1 border border-divider rounded">
<div
class="flex flex-1 min-w-52 border border-divider rounded whitespace-nowrap overflow-auto hide-scrollbar"
>
<div class="relative flex">
<label for="method">
<tippy
@@ -34,7 +36,7 @@
</label>
</div>
<div
class="flex flex-1 border-l border-divider transition rounded-r bg-primaryLight"
class="flex flex-1 border-l border-divider transition rounded-r bg-primaryLight whitespace-nowrap overflow-auto hide-scrollbar"
>
<SmartEnvInput
v-model="newEndpoint"

View File

@@ -4,11 +4,13 @@
-->
<template>
<div class="env-input-container">
<div
class="flex flex-1 items-center flex-shrink-0 whitespace-nowrap overflow-auto hide-scrollbar"
>
<div
ref="editor"
:placeholder="placeholder"
class="env-input"
class="flex flex-1"
:class="styles"
@keydown.enter.prevent="emit('enter', $event)"
@keyup="emit('keyup', $event)"
@@ -146,17 +148,3 @@ watch(editor, () => {
}
})
</script>
<style lang="scss" scoped>
.env-input-container {
@apply relative;
@apply flex;
@apply flex-1;
@apply items-center;
}
.env-input {
@apply flex;
@apply flex-1;
}
</style>