link to id html smooth scroll code example

Example: css smooth scroll to id

<style>
        @@keyframes animateright{from{right:-300px;opacity:0} to{right:0;opacity:1}}
    </style>         

   $(document).on('click', 'a[href^="#"]', function (e) {
                // target element id
                var id = $(this).attr('href');

                // target element
                var $id = $(id);
                if ($id.length === 0) {
                    return;
                }

                // prevent standard hash navigation (avoid blinking in IE)
                e.preventDefault();

                // top position relative to the document
                var pos = $id.offset().top;

                // animated top scrolling
                $('body, html').animate({ scrollTop: pos });

              // remove css from element
                $('.dataTables_wrapper').css({ 'position': 'unset', 'animation': 'unset' });
         	
			  // add the class or element you want to make css  
    		  $(id).next('.dataTables_wrapper').css({ 'position': 'relative', 'animation': 'animateright 1.5s' })
            });