UNPKG

@moamfar/react-time-date-picker

Version:

A React component library providing elegant and intuitive iOS-style pickers for Gregorian dates times and Jalaali (Persian) dates and Hijri dates offering a consistent user experience in your React applications.

63 lines (60 loc) 1.46 kB
.embla { max-width: 48rem; margin: auto; position: relative; --slide-height: 12rem; --slide-spacing: 0.2rem; --slide-size: 2.5rem; } .embla__viewport { overflow: hidden; } .embla__container { display: flex; touch-action: pan-x pinch-zoom; margin-top: calc(var(--slide-spacing) * -1); height: calc(var(--slide-spacing) + var(--slide-height)); flex-direction: column; } .embla-parent { position: relative; } .top-gradient { top: -0.5px; position: absolute; left: 0; right: 0; height: calc(50% - 32px / 2); z-index: 1; pointer-events: none; touch-action: none; border-bottom-width: 1.5px; border-style: solid; border-image: linear-gradient(to right, #fff, #a9a9a9, #fff) 1; background: linear-gradient(to top, rgba(255, 255, 255, 0.75) 0%, rgba(255, 255, 255, 1) 100%); } .bottom-gradient { position: absolute; left: 0; right: 0; height: calc(50% - 32px / 2); z-index: 1; pointer-events: none; touch-action: none; bottom: -0.5px; border-top-width: 1.5px; border-style: solid; border-image: linear-gradient(to right, #fff, #a9a9a9, #fff) 1; background: linear-gradient(to bottom, rgba(255, 255, 255, 0.75) 0%, rgba(255, 255, 255, 1) 100%); } .embla__slide { transform: translate3d(0, 0, 0); flex: 0 0 var(--slide-size); width: 100%; align-items: center; justify-content: center; display: flex; min-height: 0; user-select: none; padding-top: var(--slide-spacing); }