0
Fork 0
mirror of https://github.com/withastro/astro.git synced 2025-03-24 23:21:57 -05:00

[ci] update lockfile (#9519)

* [ci] update lockfile

* Fix errors

* Better Vue workaround

---------

Co-authored-by: matthewp <matthewp@users.noreply.github.com>
Co-authored-by: bluwy <bjornlu.dev@gmail.com>
This commit is contained in:
Houston (Bot) 2023-12-27 09:37:04 -08:00 committed by GitHub
parent 337ca508bd
commit 134367427b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 1523 additions and 1757 deletions

View file

@ -37,8 +37,9 @@ describe('Client only components', () => {
);
const css = stylesheets.join('');
expect(css).to.match(/yellowgreen/, 'Svelte styles are added');
expect(css).to.match(/Courier New/, 'Global styles are added');
// yellowgreen minified
expect(css).to.contain('#9acd32', 'Svelte styles are added');
expect(css).to.include('Courier New', 'Global styles are added');
});
it('Adds the CSS to the page - standalone svelte component', async () => {
@ -102,8 +103,9 @@ describe('Client only components subpath', () => {
);
const css = stylesheets.join('');
expect(css).to.match(/yellowgreen/, 'Svelte styles are added');
expect(css).to.match(/Courier New/, 'Global styles are added');
// yellowgreen minified
expect(css).to.contain('#9acd32', 'Svelte styles are added');
expect(css).to.include('Courier New', 'Global styles are added');
});
it('Adds the CSS to the page for TSX components', async () => {

View file

@ -101,9 +101,9 @@ describe('CSS ordering - import order', () => {
const content = await Promise.all(getLinks(html).map((href) => getLinkContent(href)));
const [{ css }] = content;
let idx1 = css.indexOf('whitesmoke');
let idx2 = css.indexOf('aliceblue');
let idx3 = css.indexOf('burlywood');
let idx1 = css.indexOf('#f5f5f5'); // whitesmoke minified
let idx2 = css.indexOf('#f0f8ff'); // aliceblue minified
let idx3 = css.indexOf('#deb887'); // burlywoord minified
expect(idx1).to.be.greaterThan(idx2);
expect(idx2).to.be.greaterThan(idx3);
@ -147,8 +147,8 @@ describe('CSS ordering - import order', () => {
getLinks(html).map((href) => getLinkContent(href, fixture))
);
let [link1, link2] = content;
expect(link1.css).to.contain('aliceblue');
expect(link2.css).to.contain('yellow');
expect(link1.css).to.contain('f0f8ff'); // aliceblue minified
expect(link2.css).to.contain('#ff0'); // yellow minified
});
});
});

View file

@ -3,11 +3,17 @@ import vue from '@astrojs/vue';
// https://astro.build/config
export default defineConfig({
integrations: [vue({
template: {
compilerOptions: {
isCustomElement: tag => tag.includes('my-button')
}
}
})],
});
integrations: [
vue({
template: {
compilerOptions: {
isCustomElement: (tag) => tag.includes('my-button'),
},
// Don't transform img src to imports
transformAssetUrls: {
includeAbsolute: false,
},
},
}),
],
});

View file

@ -73,7 +73,6 @@ async function getViteConfiguration({
}
if (!resolvedOptions.preprocess && !(await svelteConfigHasPreprocess(root))) {
// @ts-expect-error there's a bug with the types where the first arg should be optional
resolvedOptions.preprocess = vitePreprocess();
}

3237
pnpm-lock.yaml generated

File diff suppressed because it is too large Load diff