# ultimate-store-kit/3.1.0/src/js/widgets/page-checkout.js

Ultimate Store Kit – Store Builder Addons for Elementor, WooCommerce Store Builder, EDD Store Builder, version 3.1.0. 44 lines.

- Page: https://pluginprobe.com/plugins/ultimate-store-kit/3.1.0/code/src/js/widgets/page-checkout.js
- Raw: https://pluginprobe.com/plugins/ultimate-store-kit/3.1.0/raw/src/js/widgets/page-checkout.js
- Modified: 2026-08-17T09:34:16+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/ultimate-store-kit/3.1.0/code/src/js/widgets/page-checkout.js#L10-L20`.

```javascript
; (function ($, elementor) {
    $(window).on('elementor/frontend/init', function () {
        let ModuleHandler = elementorModules.frontend.handlers.Base,
            ShippingForm
        ShippingForm = ModuleHandler.extend({
            bindEvents: function () {
                this.run()
            },
            run: function (key) {
                var element = this.findElement('.elementor-widget').get(0);
                if (jQuery(this.$element).hasClass('elementor-section')) {
                    element = this.$element.get(0)
                }
                var $container = this.$element.find(".usk-page-checkout");
                if (!$container.length) {
                    return;
                }
                var usk_shipping_form = {
                    $checkout_form: $('.usk-page-checkout'),
                    init: function () {
                        this.$checkout_form.on('change', '#ship-to-different-address input', this.ship_to_different_address);
                        this.$checkout_form.find('#ship-to-different-address input').trigger('change');
                    },
                    ship_to_different_address: function () {
                        $('div.shipping_address').hide();
                        if ($(this).is(':checked')) {
                            $('div.shipping_address').slideDown();
                        }
                    },
                };
                usk_shipping_form.init();
            }
        })
        elementorFrontend.hooks.addAction(
            'frontend/element_ready/usk-page-checkout.default',
            function ($scope) {
                elementorFrontend.elementsHandler.addHandler(ShippingForm, {
                    $element: $scope
                })
            }
        )
    })
})(jQuery, window.elementorFrontend)

```
