import{isString as l,isRegExp as o}from"../../utils/validateTypes.mjs";import e from"../../utils/isStandardSyntaxDeclaration.mjs";import r from"../../utils/optionsMatches.mjs";import t from"../../utils/report.mjs";import i from"../../utils/ruleMessages.mjs";import n from"../../utils/validateOptions.mjs";const s="property-no-deprecated",a=i(s,{expected:(l,o)=>`Expected "${l}" to be "${o}"`,rejected:l=>`Unexpected deprecated property "${l}"`}),p={"-khtml-box-align":"align-items","-khtml-box-direction":null,"-khtml-box-flex":"flex-grow","-khtml-box-lines":null,"-khtml-box-ordinal-group":"order","-khtml-box-orient":null,"-khtml-box-pack":null,"-khtml-user-modify":null,"-moz-box-align":"align-items","-moz-box-direction":null,"-moz-box-flex":"flex-grow","-moz-box-lines":null,"-moz-box-ordinal-group":"order","-moz-box-orient":null,"-moz-box-pack":null,"-moz-user-modify":null,"-ms-box-align":"align-items","-ms-box-direction":null,"-ms-box-flex":"flex-grow","-ms-box-lines":null,"-ms-box-ordinal-group":"order","-ms-box-orient":null,"-ms-box-pack":null,"-webkit-box-align":"align-items","-webkit-box-direction":null,"-webkit-box-flex":"flex-grow","-webkit-box-lines":null,"-webkit-box-ordinal-group":"order","-webkit-box-orient":null,"-webkit-box-pack":null,"-webkit-user-modify":null,"grid-column-gap":"column-gap","grid-gap":"gap","grid-row-gap":"row-gap","ime-mode":null,"page-break-after":"break-after","page-break-before":"break-before","page-break-inside":"break-inside","position-try-options":"position-try-fallbacks","scroll-snap-coordinate":null,"scroll-snap-destination":null,"scroll-snap-margin-bottom":"scroll-margin-bottom","scroll-snap-margin-left":"scroll-margin-left","scroll-snap-margin-right":"scroll-margin-right","scroll-snap-margin-top":"scroll-margin-top","scroll-snap-margin":"scroll-margin","scroll-snap-points-x":null,"scroll-snap-points-y":null,"scroll-snap-type-x":null,"scroll-snap-type-y":null,"word-wrap":"overflow-wrap",clip:null},m=(i,m)=>(u,b)=>{n(b,s,{actual:i},{actual:m,possible:{ignoreProperties:[l,o]},optional:!0})&&u.walkDecls(l=>{if(!e(l))return;const{prop:o,value:i}=l;if(r(m,"ignoreProperties",o))return;const n=o.toLowerCase(),u=p[n];if(void 0===u)return;if("-webkit-box-orient"===n&&"vertical"===i.toLowerCase())return;let g,x,d=[];u?(x=a.expected,d=[o,u],g=()=>{l.prop=u}):(x=a.rejected,d=[o]),t({message:x,messageArgs:d,node:l,index:0,endIndex:o.length,result:b,ruleName:s,fix:{apply:g,node:l}})})};m.ruleName=s,m.messages=a,m.meta={url:"https://stylelint.io/user-guide/rules/property-no-deprecated",fixable:!0};export{m as default};