import{isRegExp as e,isString as r}from"../../utils/validateTypes.mjs";import t from"../../utils/isKeyframeRule.mjs";import s from"../../utils/isStandardSyntaxRule.mjs";import o from"../../utils/matchesStringOrRegExp.mjs";import l from"../../utils/optionsMatches.mjs";import i from"../../utils/report.mjs";import m from"../../utils/ruleMessages.mjs";import a from"../../utils/validateObjectWithArrayProps.mjs";import u from"../../utils/validateOptions.mjs";const p="rule-selector-property-disallowed-list",n=m(p,{rejected:(e,r)=>`Unexpected property "${r}" for selector "${e}"`}),f=(m,f)=>(c,d)=>{if(!u(d,p,{actual:m,possible:[a(r,e)]},{actual:f,possible:{ignore:["keyframe-selectors"]},optional:!0}))return;const j=l(f,"ignore","keyframe-selectors"),y=Object.keys(m);c.walkRules(e=>{if(!s(e))return;if(j&&t(e))return;const r=y.find(r=>o(e.selector,r));if(!r)return;const l=m[r];l&&e.walkDecls(r=>{if(!function(e,r){let t=e.parent;for(;t;){if(t===r)return!0;if("rule"===t.type)return!1;t=t.parent}return!1}(r,e))return;const{prop:t}=r;o(t,l)&&i({message:n.rejected,messageArgs:[e.selector,t],node:r,result:d,ruleName:p,word:t})})})};f.ruleName=p,f.messages=n,f.meta={url:"https://stylelint.io/user-guide/rules/rule-selector-property-disallowed-list"};export{f as default};