import{isString as e,isRegExp as r}from"../../utils/validateTypes.mjs";import{basicKeywords as t}from"../../reference/keywords.mjs";import s from"../../utils/isAutoprefixable.mjs";import o from"../../utils/optionsMatches.mjs";import i from"../../utils/report.mjs";import p from"../../utils/ruleMessages.mjs";import l from"../../utils/validateOptions.mjs";import u from"../../utils/vendor.mjs";const m="property-no-vendor-prefix",a=p(m,{rejected:e=>`Unexpected vendor-prefixed property "${e}"`}),n=(p,n)=>(f,d)=>{l(d,m,{actual:p},{optional:!0,actual:n,possible:{ignoreProperties:[e,r]}})&&f.walkDecls(e=>{const r=e.prop,p=u.unprefixed(r);if(o(n,"ignoreProperties",p))return;if("-"!==r[0]||"-"===r[1])return;if(!s.property(r))return;if("-webkit-background-size"===r){if(!e.value.split(",").every(e=>{const r=e.trim().split(/\s+/),s=r.length,[o]=r;switch(s){case 2:return!0;case 1:return o&&("auto"===o||t.has(o));default:return!1}}))return}i({message:a.rejected,messageArgs:[r],word:r,node:e,result:d,ruleName:m,fix:{apply:()=>{e.prop=s.unprefix(e.prop)},node:e}})})};n.ruleName=m,n.messages=a,n.meta={url:"https://stylelint.io/user-guide/rules/property-no-vendor-prefix",fixable:!0};export{n as default};