时间选择器显示优化
This commit is contained in:
parent
5732906583
commit
14f1b2f5eb
|
@ -1,10 +1,6 @@
|
|||
import {css} from 'lit'
|
||||
|
||||
export default css`
|
||||
/* 滚轮被选项透明化,防止遮挡 */
|
||||
.hasSelected {
|
||||
opacity: 0;
|
||||
}
|
||||
.p-scroll {
|
||||
position: fixed;
|
||||
bottom: 0;
|
||||
|
@ -203,6 +199,7 @@ export default css`
|
|||
margin: 0;
|
||||
padding: 0;
|
||||
position: relative;
|
||||
opacity: 0;
|
||||
}
|
||||
.p-select-list,
|
||||
.p-select-wheel,
|
||||
|
@ -235,7 +232,6 @@ export default css`
|
|||
/* z-index: 100; */
|
||||
pointer-events: none;
|
||||
box-sizing: border-box;
|
||||
background: linear-gradient( 134.78deg, #f7f5f7 2.34%, #fafafa 34.11%, #e1e4f2 100% );
|
||||
}
|
||||
.p-select-line:before,
|
||||
.p-select-line:after {
|
||||
|
@ -244,7 +240,7 @@ export default css`
|
|||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
height: 1px;
|
||||
/* height: 1px; */
|
||||
-webkit-transform: scaleY(0.5);
|
||||
background: #a5a5a5;
|
||||
}
|
||||
|
@ -483,4 +479,10 @@ export default css`
|
|||
top: 29px;
|
||||
left: 532px;
|
||||
}
|
||||
/* 滚轮不选项透明化 */
|
||||
.hasSelected {
|
||||
opacity: 1;
|
||||
font-size: 36px !important;
|
||||
color: #1d98f0 !important;
|
||||
}
|
||||
`
|
||||
|
|
|
@ -370,7 +370,7 @@ export class PickerBase extends LitElement {
|
|||
function getVal(
|
||||
pos: number,
|
||||
data: itemdate[],
|
||||
infinite: boolean,
|
||||
// infinite: boolean,
|
||||
selectedIdx: number
|
||||
) {
|
||||
let len = data.length,
|
||||
|
@ -411,7 +411,7 @@ export class PickerBase extends LitElement {
|
|||
}, 300)
|
||||
}
|
||||
class Scroll {
|
||||
el: any = 'test'
|
||||
el: any
|
||||
wheel: any
|
||||
index: any
|
||||
opt: any
|
||||
|
@ -708,7 +708,7 @@ export class PickerBase extends LitElement {
|
|||
let res = getVal(
|
||||
this.opt.scrollY,
|
||||
this.opt.data,
|
||||
this.opt.infinite,
|
||||
// this.opt.infinite,
|
||||
this.opt.selectedIdx
|
||||
)
|
||||
_this.rs.result[this.index] = res
|
||||
|
@ -805,7 +805,7 @@ export class PickerBase extends LitElement {
|
|||
let res = getVal(
|
||||
scroll.opt.scrollY,
|
||||
scroll.opt.data,
|
||||
scroll.opt.infinite,
|
||||
// scroll.opt.infinite,
|
||||
scroll.opt.selectedIdx
|
||||
)
|
||||
_this.rs.result.push(res)
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
<svg width="48" height="48" viewBox="0 0 48 48" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M8.5 25L19.52 35L40 13" stroke="#1D98F0" stroke-width="3" stroke-linecap="square" stroke-linejoin="round"/>
|
||||
</svg>
|
After Width: | Height: | Size: 220 B |
|
@ -0,0 +1,3 @@
|
|||
<svg width="48" height="48" viewBox="0 0 48 48" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M13 35L35 13M13 13L35 35" stroke="#4D4D4D" stroke-width="3" stroke-linecap="square" stroke-linejoin="round"/>
|
||||
</svg>
|
After Width: | Height: | Size: 222 B |
Loading…
Reference in New Issue