This repository has been archived on 2023-08-30. You can view files and clone it, but cannot push or open issues/pull-requests.
bytedo
/
wcui
Archived
1
0
Fork 0
wcui/src/picker/date.wc

81 lines
1.3 KiB
Plaintext
Raw Normal View History

2019-07-29 16:05:42 +08:00
<template>
2019-07-29 17:01:47 +08:00
<label class="input">
<input readonly type="text" />
<wc-icon class="icon" is="key"></wc-icon>
</label>
<div class="calendar">
<header>
<wc-icon is="key"></wc-icon>
<wc-icon is="key"></wc-icon>
<wc-icon is="key"></wc-icon>
<wc-icon is="key"></wc-icon>
<span>2019-07</span>
</header>
</div>
2019-07-29 16:05:42 +08:00
</template>
<style lang="scss">
:host {
display: inline-block;
2019-07-29 17:01:47 +08:00
user-select: none;
-moz-user-select: none;
color: nth($cd, 2);
border-radius: 4px;
}
.input {
display: flex;
justify-content: center;
align-items: center;
min-width: 64px;
height: 32px;
font-size: 14px;
border: 1px solid nth($cp, 3);
border-radius: inherit;
background: #fff;
color: inherit;
cursor: text;
input {
min-width: 0;
padding: 0 5px;
border: 0;
border-radius: inherit;
color: inherit;
font-size: inherit;
background: none;
outline: none;
box-shadow: none;
cursor: inherit;
&::placeholder {
color: nth($cgr, 1);
}
}
&:focus-within {
box-shadow: 0 0 3px nth($co, 1);
}
/* ----- */
.icon {
padding: 0 5px;
--size: 20px;
}
2019-07-29 16:05:42 +08:00
}
</style>
<script>
2019-07-29 17:01:47 +08:00
import '../icon/index'
2019-07-29 16:05:42 +08:00
export default class DatePicker {
props = {
2019-07-29 17:01:47 +08:00
value: '',
format: 'Y-m-d'
2019-07-29 16:05:42 +08:00
}
constructor() {
/* render */
}
}
</script>