You can do some workaround in getAttributes() function of vendor/magento/module-catalog/Helper/Product/Edit/Action/Attribute.php class (don't forget to preference the class).
public function getAttributes()
{
if ($this->_attributes === null) {
$this->_attributes = $this->_eavConfig->getEntityType(
\Magento\Catalog\Model\Product::ENTITY
)->getAttributeCollection()->addIsNotUniqueFilter()->setInAllAttributeSetsFilter(
$this->getProductsSetIds()
)->join(
'catalog_eav_attribute',
'main_table.attribute_id = catalog_eav_attribute.attribute_id',
'position'
);
if ($this->_excludedAttributes) {
$this->_attributes->addFieldToFilter('attribute_code', ['nin' => $this->_excludedAttributes]);
}
$this->_attributes->setOrder('catalog_eav_attribute.position', 'DESC');
// check product type apply to limitation and remove attributes that impossible to change in mass-update
$productTypeIds = $this->getProducts()->getProductTypeIds();
foreach ($this->_attributes as $attribute) {
/* @var $attribute \Magento\Catalog\Model\Entity\Attribute */
foreach ($productTypeIds as $productTypeId) {
$applyTo = $attribute->getApplyTo();
if (count($applyTo) > 0 && !in_array($productTypeId, $applyTo)) {
$this->_attributes->removeItemByKey($attribute->getId());
break;
}
}
}
}
return $this->_attributes;
}
Here I have joined the catalog_eav_attribute table and sorted the attribute collection desc by the position of the attribute.
(Please note that the position attribute is used as "Position of attribute in layered navigation block")
You can do something similar for this.