I have this string = rgb(192, 194, 194) -10px -10px 0px; I need to get the first -10px in that string and store as a variable. That number is dynamic and will change.
Thanks for the help. Here is what I have. I'm grabbing the text-shadow of a span and need to get the -10px value which will be added to the tooltip. This is a dynamic number that will change based on where a user clicks on a slider. I just cant figureout how to parse that string to get the -10px value.
$('.slider-track.shadow').on('click', function (e) {
e.preventDefault();
var currentValue = $('.editing').find('span').css('text-shadow');
var replaceValue = currentValue.replace(/\D/g, '');
console.log(currentValue);
$('.tooltip-inner.shadow').text(currentValue);
});