css3 - css scale background to a certain ratio of image -
is there css3 method of scaling background image of element ratio of image's dimensions?
all of documentation find when searching suggests 'background-size', when percentage given there, percentage of element background belongs. want scale relative size of background image itself.
is 1 need ? try link https://jsfiddle.net/beljems/dtxljmdv/. added padding
percentage value top , bottom, no height
required. , uses background-size:cover
.
hope helps.
wiki
Comments
Post a Comment