WIP Добавила date picker

This commit is contained in:
Daria Golova
2023-05-26 17:10:46 +03:00
parent 93e4c93a96
commit 7670ab5a99
2 changed files with 22 additions and 3 deletions

View File

@@ -31,7 +31,9 @@
) )
template(v-slot:prepend, v-if="iconLeft") template(v-slot:prepend, v-if="iconLeft")
slot slot
slot.cursor-pointer(v-if="!iconLeft") template(v-slot:append, v-if="iconRight")
slot
slot.cursor-pointer(v-if="!iconLeft && !iconRight")
</template> </template>
<script> <script>
@@ -112,6 +114,7 @@ export default {
label: String, label: String,
readonly: Boolean, readonly: Boolean,
iconLeft: Boolean, iconLeft: Boolean,
iconRight: Boolean,
name: String, name: String,
}, },
emits: ["update:modelValue"], emits: ["update:modelValue"],

View File

@@ -23,9 +23,23 @@
outlined, outlined,
:width="300", :width="300",
fontSize="16px", fontSize="16px",
lineHeight="19px" lineHeight="19px",
iconRight
) )
q-icon.text(name="app:calendar", size="20px") q-icon.text(name="app:calendar", size="20px")
q-popup-proxy(
cover,
transition-show="scale",
transition-hide="scale"
)
q-date(v-model="date", minimal)
.flex.items-center.justify-end
q-btn(
v-close-popup,
label="Закрыть",
color="primary",
flat
)
q-btn( q-btn(
color="secondary", color="secondary",
icon="arrow_forward_ios", icon="arrow_forward_ios",
@@ -34,7 +48,7 @@
text-color="primary", text-color="primary",
dense dense
) )
.h-10.p-1.flex.items-center.justify-between.bg-secondary.rounded.text-grey-color .h-10.p-1.flex.items-center.justify-between.bg-secondary.rounded.text-grey-color.ml-52
q-btn-toggle( q-btn-toggle(
v-model="displayType", v-model="displayType",
:options="displayTypesList", :options="displayTypesList",
@@ -46,6 +60,7 @@
<script> <script>
import BaseInput from "@/components/base/BaseInput"; import BaseInput from "@/components/base/BaseInput";
import * as moment from "moment/moment";
export default { export default {
name: "CalendarHeader", name: "CalendarHeader",
components: { BaseInput }, components: { BaseInput },
@@ -62,6 +77,7 @@ export default {
value: "expanded", value: "expanded",
}, },
], ],
date: moment(),
}; };
}, },
}; };