import e from"../../../stylelint/lib/index.mjs";import{getContainingNode as r}from"../../utils/getContainingNode.mjs";import{isRuleWithNodes as i}from"../../utils/isRuleWithNodes.mjs";import{isNumber as t}from"../../utils/validateType.mjs";import{checkNodeForOrder as o}from"./checkNodeForOrder.mjs";import{checkNodeForEmptyLines as m}from"./checkNodeForEmptyLines.mjs";import{createOrderInfo as s}from"./createOrderInfo.mjs";import{validatePrimaryOption as p}from"./validatePrimaryOption.mjs";import{ruleName as n}from"./ruleName.mjs";import{messages as l}from"./messages.mjs";function d(l,d={},a={}){return function(u,f){if(!e.utils.validateOptions(f,n,{actual:l,possible:p},{actual:d,possible:{unspecified:["top","bottom","ignore","bottomAlphabetical"],emptyLineBeforeUnspecified:["always","never","threshold"],emptyLineMinimumPropertyThreshold:t},optional:!0}))return;let c=s(l),y=[];u.walk(function(e){let t=r(e);y.includes(t)||(y.push(t),i(t)&&(o({node:t,primaryOption:l,unspecified:d.unspecified||"ignore",result:f,expectedOrder:c}),m({node:t,context:a,emptyLineBeforeUnspecified:d.emptyLineBeforeUnspecified,emptyLineMinimumPropertyThreshold:d.emptyLineMinimumPropertyThreshold||0,expectedOrder:c,primaryOption:l,result:f})))})}}d.primaryOptionArray=!0,d.ruleName=n,d.messages=l,d.meta={fixable:!0,url:"https://github.com/hudochenkov/stylelint-order/blob/master/rules/properties-order/README.md"};export{d as rule};