403Webshell
Server IP : 138.197.176.125  /  Your IP : 216.73.217.54
Web Server : Apache/2.4.41 (Ubuntu)
System : Linux SuiteCRM-8 5.4.0-216-generic #236-Ubuntu SMP Fri Apr 11 19:53:21 UTC 2025 x86_64
User : root ( 0)
PHP Version : 8.3.19
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /var/www/smartsync-180820261/node_modules/tailwindcss/src/util/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /var/www/smartsync-180820261/node_modules/tailwindcss/src/util/validateFormalSyntax.js
import { length, percentage } from './dataTypes'
import { splitAtTopLevelOnly } from './splitAtTopLevelOnly'

/**
 *
 * https://developer.mozilla.org/en-US/docs/Web/CSS/background-size#formal_syntax
 *
 * background-size =
 *  <bg-size>#
 *
 * <bg-size> =
 *   [ <length-percentage [0,∞]> | auto ]{1,2}  |
 *   cover                                      |
 *   contain
 *
 * <length-percentage> =
 *   <length>      |
 *   <percentage>
 *
 * @param {string} value
 */
export function backgroundSize(value) {
  let keywordValues = ['cover', 'contain']
  // the <length-percentage> type will probably be a css function
  // so we have to use `splitAtTopLevelOnly`
  return splitAtTopLevelOnly(value, ',').every((part) => {
    let sizes = splitAtTopLevelOnly(part, '_').filter(Boolean)
    if (sizes.length === 1 && keywordValues.includes(sizes[0])) return true

    if (sizes.length !== 1 && sizes.length !== 2) return false

    return sizes.every((size) => length(size) || percentage(size) || size === 'auto')
  })
}

Youez - 2016 - github.com/yon3zu
LinuXploit