Feat : login sys
Some checks failed
Build and Push Docker Images / docker (push) Failing after 11s

This commit is contained in:
jeanotx32
2026-05-18 22:44:02 -04:00
parent cf0b3f0acf
commit d799ae503c
6808 changed files with 856331 additions and 45 deletions

View File

@@ -0,0 +1,28 @@
"use strict"
const startsWithKeywordRegexp = /^(all|not|only|print|screen)/i
module.exports = function (parentMedia, childMedia) {
if (!parentMedia.length && childMedia.length) return childMedia
if (parentMedia.length && !childMedia.length) return parentMedia
if (!parentMedia.length && !childMedia.length) return []
const media = []
parentMedia.forEach(parentItem => {
const parentItemStartsWithKeyword = startsWithKeywordRegexp.test(parentItem)
childMedia.forEach(childItem => {
const childItemStartsWithKeyword = startsWithKeywordRegexp.test(childItem)
if (parentItem !== childItem) {
if (childItemStartsWithKeyword && !parentItemStartsWithKeyword) {
media.push(`${childItem} and ${parentItem}`)
} else {
media.push(`${parentItem} and ${childItem}`)
}
}
})
})
return media
}