JavaScript UI Libraries & Blazor Components Suite – Smart UI Forums Date & Time Pickers DateTimePicker showing todays date as highlighted number – turn off?

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #101703
    davout
    Member
    Up
    0
    Down

    I’ve noticed that the DateTimePicker drop down for date selection highlights todays date.  Is there a way to turn this off?

    #101707
    yavordashew
    Member
    Up
    0
    Down

    Hi davout,
    By default the DateTimePicker in the dropdown(pop-up) will highlight the todays date in the dropdown even if the nullable property is set to true.
    However there is a way to achieve this and you can check the solution in the code snippet below :
    //In your HTML file:

        <smart-date-time-picker
                              calendar-button
                              enable-mouse-wheel-action
                              spin-buttons
                              spin-buttons-position="left"
                              nullable
                              value = 'null'
                              hide-tooltip-arrow
                            >
                            </smart-date-time-picker> 

    Note that I have set the nullable property to true and set the DAteTimePicker value to null
    And in your CSS:
    /* Necessery styles for the initial selected date */

    .smart-calendar .smart-calendar-week .smart-calendar-cell[today]{
        background-color: white;
        color: black;
        border-color: transparent;
    }

    Please, do not hesitate to contact us if you have any additional questions.
    Best regards,
    Yavor Dashev
    Smart UI Team
    https://www.htmlelements.com/

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.