All files / src/compiler/phases css.js

100% Statements 14/14
100% Branches 2/2
100% Functions 2/2
100% Lines 14/14

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 152x 2x 2x 2x 2x 2x 2x 2x 2x 1441x 1441x 2x 2x 2x  
/** @import { Css } from '#compiler' */
const regex_css_browser_prefix = /^-((webkit)|(moz)|(o)|(ms))-/;
export const regex_css_name_boundary = /^[\s,;}]$/;
 
/**
 * @param {string} name
 * @returns {string}
 */
export function remove_css_prefix(name) {
	return name.replace(regex_css_browser_prefix, '');
}
 
/** @param {Css.Atrule} node */
export const is_keyframes_node = (node) => remove_css_prefix(node.name) === 'keyframes';