Quantity and weight changes simultaneously

Topic summary

A developer seeks to implement dual quantity/weight controls on Shopify product pages where:

Desired Functionality:

  • Two separate increment/decrement fields (quantity and weight)
  • Fields operate synchronously—changing quantity automatically adjusts weight proportionally
  • Price updates dynamically based on these changes
  • Reference example provided from floorscenter.com showing this feature in action

Proposed Solution:
A respondent suggests implementing this through JavaScript by:

  • Triggering change events on the input fields
  • Applying calculation logic to update the dependent field values

Status: The question remains open with only a high-level technical direction provided. No detailed implementation code or step-by-step guidance has been shared yet.

Summarized with AI on November 2. AI used: claude-sonnet-4-5-20250929.

i want to achieve a functionality in shopify.
on product detail page there will be 2 fields to increase and decrease. One for quantity and other for weight. both the fields work simultanuously like if we increase quantity by 2 weight will be multiplied by 2 and price will be updated. I have attached the example of what i want actually. Here is the website where this functionality is applied. https://floorscenter.com/collections/browse-our-items/products/emser-cabo-13-x-13-ceramic-matte-tile

How can i achieve this in shopify.
Thanks in advance

Hi @ahmedrazashaikh
It will require to do with javascript. You need to trigger change event apply logic to calculate another field