src/components/ebay-carousel/index.js
function getMaxOffset({ items, slideWidth }) {
    if (!items.length) {
        return 0;
    }
    return Math.max(items[items.length - 1].right - slideWidth, 0) || 0;
}
function getMaxOffset({ items, slideWidth }) {
    if (!items.length) {
        return 0;
    }
    return Math.max(items[items.length - 1].right - slideWidth, 0) || 0;
}
function getMaxOffset ( { items , slideWidth } ) { if ( ! items . length ) { return 0 ; } return Math . max ( items [ items . length - 1 ] . right - slideWidth , 0 ) || 0 ; }
Given the current widget state, finds the last valid offset.

@param {object} state The widget state.
@return {number}
Given the current widget state finds the last valid offset .