Skip to content

Commit

Permalink
chore: test update
Browse files Browse the repository at this point in the history
  • Loading branch information
zyyv committed Dec 20, 2023
1 parent 7c71b4c commit 4f68e2b
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
14 changes: 7 additions & 7 deletions test/__snapshots__/index.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,17 @@

exports[`preset-useful > targets 1`] = `
"/* layer: default */
.\\\\@active\\\\:bg-red.active{--un-bg-opacity:1;background-color:rgba(248,113,113,var(--un-bg-opacity));}
.text-\\\\[rgb\\\\(--c\\\\)\\\\]\\\\:50{color:rgba(--c,0.5);}
.\\@active\\:bg-red.active{--un-bg-opacity:1;background-color:rgba(248,113,113,var(--un-bg-opacity));}
.text-\\[rgb\\(--c\\)\\]\\:50{color:rgba(--c,0.5);}
/* layer: useful */
.c-context\\\\:\\\\:\\\\#818181{--c-context:129,129,129;}
.c-custom\\\\:\\\\:red{--c-custom:248,113,113;}
.c\\\\:\\\\:red{--c:248,113,113;}
.p-10\\\\:\\\\:10px{--p-10:10px;}
.c-context\\:\\:\\#818181{--c-context:129,129,129;}
.c-custom\\:\\:red{--c-custom:248,113,113;}
.c\\:\\:red{--c:248,113,113;}
.p-10\\:\\:10px{--p-10:10px;}
.p-c{position:absolute;left:50%;top:50%;--un-translate-x:-50%;transform:translateX(var(--un-translate-x)) translateY(var(--un-translate-y)) translateZ(var(--un-translate-z)) rotate(var(--un-rotate)) rotateX(var(--un-rotate-x)) rotateY(var(--un-rotate-y)) rotateZ(var(--un-rotate-z)) skewX(var(--un-skew-x)) skewY(var(--un-skew-y)) scaleX(var(--un-scale-x)) scaleY(var(--un-scale-y)) scaleZ(var(--un-scale-z));--un-translate-y:-50%;}
.pa{position:absolute;}
.pr{position:relative;}
.hover\\\\:pr:hover{position:relative;}
.hover\\:pr:hover{position:relative;}
.f-c{display:flex;align-items:center;justify-content:center;}
.f-c-c{display:flex;flex-direction:column;align-items:center;justify-content:center;}
.fb{display:flex;justify-content:space-between;}
Expand Down
2 changes: 1 addition & 1 deletion test/extractor.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ describe('presetUseful extractor', () => {
expect(matched.size).toBe(1)
expect(css).toMatchInlineSnapshot(`
"/* layer: default */
.bg-\\\\[url\\\\(data\\\\:image\\\\/png\\\\;base64\\\\,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8BQDwAEhQGAhKmMIwAAAABJRU5ErkJggg\\\\=\\\\=\\\\)\\\\]{--un-url:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8BQDwAEhQGAhKmMIwAAAABJRU5ErkJggg==);background-image:var(--un-url);}"
.bg-\\[url\\(data\\:image\\/png\\;base64\\,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8BQDwAEhQGAhKmMIwAAAABJRU5ErkJggg\\=\\=\\)\\]{--un-url:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8BQDwAEhQGAhKmMIwAAAABJRU5ErkJggg==);background-image:var(--un-url);}"
`)
})
})
4 changes: 2 additions & 2 deletions test/postprocess.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,10 @@ describe('presetUseful postprocess with important', () => {
"/* layer: default */
.important-ma{margin:auto !important;}
.bg-red{--un-bg-opacity:1 !important;background-color:rgb(248 113 113 / var(--un-bg-opacity)) !important;}
.\\\\!text-xl{font-size:1.25rem !important;line-height:1.75rem !important;}
.\\!text-xl{font-size:1.25rem !important;line-height:1.75rem !important;}
.text-blue{--un-text-opacity:1 !important;color:rgb(96 165 250 / var(--un-text-opacity)) !important;}
@media (min-width: 640px){
.sm\\\\:text-sm\\\\!{font-size:0.875rem !important;line-height:1.25rem !important;}
.sm\\:text-sm\\!{font-size:0.875rem !important;line-height:1.25rem !important;}
}"
`)
})
Expand Down

0 comments on commit 4f68e2b

Please sign in to comment.