xxxxxxxxxx
1
<template>
2
<section class="intro">
3
<div class="bg-image vh-100" style="
4
background-color: rgb(167, 152, 239);
5
">
6
<div class="mask d-flex align-items-center h-100">
7
<MDBContainer>
8
<MDBCard>
9
<MDBCardBody class="p-4">
10
<MDBRow>
11
<MDBCol col="12">
12
<MDBInput v-model="inputValue" inputGroup="lg" placeholder="Enter keywords?" class="form-control-lg">
13
<template #prepend>
14
<MDBDropdown v-model="dropdown1">
15
<MDBDropdownToggle tag="a" color="white" class="input-group-text text-body" @click="dropdown1 = !dropdown1">Categories</MDBDropdownToggle>
16
<MDBDropdownMenu>
17
<MDBDropdownItem href="#">Accessories</MDBDropdownItem>
18
<MDBDropdownItem href="#">Clothing</MDBDropdownItem>
19
<MDBDropdownItem href="#">Footwear</MDBDropdownItem>
20
<MDBDropdownItem href="#">Ladies</MDBDropdownItem>
21
<MDBDropdownItem href="#">Men</MDBDropdownItem>
22
<MDBDropdownItem href="#">New Arrivals</MDBDropdownItem>
23
<MDBDropdownItem href="#">Sale</MDBDropdownItem>
24
</MDBDropdownMenu>
25
</MDBDropdown>
26
</template>
27
<MDBBtn color="success px-4 rounded-right">
28
<i class="fas fa-search" style="font-size: 0.75rem"></i>
29
</MDBBtn>
30
</MDBInput>
31
</MDBCol>
32
</MDBRow>
33
</MDBCardBody>
34
</MDBCard>
35
</MDBContainer>
36
</div>
37
</div>
38
</section>
39
</template>
xxxxxxxxxx
1
<style>#app {
2
font-family: Roboto, Helvetica, Arial, sans-serif;
3
}
4
5
.rounded-right {
6
border-top-right-radius: 0.3rem !important;
7
border-bottom-right-radius: 0.3rem !important;
8
}
9
10
html,
11
body,
12
.intro {
13
height: 100%;
14
}
15
16
.form-outline .form-control:focus~.form-notch .form-notch-leading {
17
border-top: 0.125rem solid #00b74a;
18
border-bottom: 0.125rem solid #00b74a;
19
border-left: 0.125rem solid #00b74a;
20
}
21
22
.form-outline .form-control:focus~.form-notch .form-notch-middle {
23
border-color: #00b74a;
24
}
25
26
.form-outline .form-control:focus~.form-notch .form-notch-trailing {
27
border-top: 0.125rem solid #00b74a;
28
border-bottom: 0.125rem solid #00b74a;
29
border-right: 0.125rem solid #00b74a;
30
}
31
32
.form-outline .form-control:focus~.form-label {
33
color: #00b74a;
34
}
35
36
.autocomplete-input.focused~.form-notch .form-notch-leading {
37
border-top: 2px solid #00b74a;
38
border-bottom: 2px solid #00b74a;
39
border-left: 2px solid #00b74a;
40
transition: all 0.2s linear;
41
}
42
43
.autocomplete-input.focused~.form-notch .form-notch-middle {
44
border-color: #00b74a;
45
}
46
47
.autocomplete-input.focused~.form-notch .form-notch-trailing {
48
border-color: #00b74a;
49
}
50
51
.autocomplete-input.focused~.autocomplete-label {
52
color: #00b74a;
53
}
54
55
</style>
xxxxxxxxxx
1
<script>
2
import {
3
MDBContainer,
4
MDBCard,
5
MDBCardBody,
6
MDBRow,
7
MDBCol,
8
MDBInput,
9
MDBDropdown,
10
MDBDropdownToggle,
11
MDBDropdownMenu,
12
MDBDropdownItem,
13
MDBBtn
14
} from "mdb-vue-ui-kit";
15
16
import { ref } from "vue"
17
18
export default {
19
name: "App",
20
components: {
21
MDBContainer,
22
MDBCard,
23
MDBCardBody,
24
MDBRow,
25
MDBCol,
26
MDBInput,
27
MDBDropdown,
28
MDBDropdownToggle,
29
MDBDropdownMenu,
30
MDBDropdownItem,
31
MDBBtn
32
},
33
setup() {
34
const inputValue = ref("");
35
const dropdown1 = ref(false)
36
37
return { inputValue, dropdown1 }
38
}
39
};
40
</script>
Console errors: 0