@spectrum-web-components/thumbnail 0.5.8-devmode.0 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +3 -3
- package/sp-thumbnail.js +1 -2
- package/sp-thumbnail.js.map +1 -1
- package/src/Thumbnail.js +4 -42
- package/src/Thumbnail.js.map +1 -1
- package/src/index.js +1 -1
- package/src/index.js.map +1 -1
- package/src/spectrum-thumbnail.css.js +2 -4
- package/src/spectrum-thumbnail.css.js.map +1 -1
- package/src/thumbnail.css.js +2 -4
- package/src/thumbnail.css.js.map +1 -1
- package/stories/images.js +1 -3
- package/stories/images.js.map +1 -1
- package/stories/thumbnail-sizes.stories.js +4 -20
- package/stories/thumbnail-sizes.stories.js.map +1 -1
- package/stories/thumbnail.stories.js +16 -50
- package/stories/thumbnail.stories.js.map +1 -1
- package/test/benchmark/basic-test.js +2 -6
- package/test/benchmark/basic-test.js.map +1 -1
- package/test/thumbnail-sizes.test-vrt.js +1 -3
- package/test/thumbnail-sizes.test-vrt.js.map +1 -1
- package/test/thumbnail.test-vrt.js +1 -3
- package/test/thumbnail.test-vrt.js.map +1 -1
- package/test/thumbnail.test.js +9 -30
- package/test/thumbnail.test.js.map +1 -1
|
@@ -1,22 +1,6 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
export default {
|
|
5
|
-
title: "Thumbnail/Sizes",
|
|
6
|
-
component: "sp-thumbnail"
|
|
7
|
-
};
|
|
8
|
-
const thumbnail = ({
|
|
9
|
-
size
|
|
10
|
-
}) => {
|
|
11
|
-
return html`
|
|
12
|
-
<sp-thumbnail size=${size}>
|
|
13
|
-
<img src=${image} alt="Woman crouching" />
|
|
1
|
+
import{html as i}from"@spectrum-web-components/base";import"@spectrum-web-components/thumbnail/sp-thumbnail.js";import{thumbnail as o}from"./images.js";export default{title:"Thumbnail/Sizes",component:"sp-thumbnail"};const t=({size:e})=>i`
|
|
2
|
+
<sp-thumbnail size=${e}>
|
|
3
|
+
<img src=${o} alt="Woman crouching" />
|
|
14
4
|
</sp-thumbnail>
|
|
15
|
-
`;
|
|
16
|
-
};
|
|
17
|
-
export const XXS = () => thumbnail({ size: "xxs" });
|
|
18
|
-
export const XS = () => thumbnail({ size: "xs" });
|
|
19
|
-
export const s = () => thumbnail({ size: "s" });
|
|
20
|
-
export const m = () => thumbnail({ size: "m" });
|
|
21
|
-
export const l = () => thumbnail({ size: "l" });
|
|
5
|
+
`;export const XXS=()=>t({size:"xxs"}),XS=()=>t({size:"xs"}),s=()=>t({size:"s"}),m=()=>t({size:"m"}),l=()=>t({size:"l"});
|
|
22
6
|
//# sourceMappingURL=thumbnail-sizes.stories.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["thumbnail-sizes.stories.ts"],
|
|
4
4
|
"sourcesContent": ["/*\nCopyright 2020 Adobe. All rights reserved.\nThis file is licensed to you under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License. You may obtain a copy\nof the License at http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software distributed under\nthe License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\nOF ANY KIND, either express or implied. See the License for the specific language\ngoverning permissions and limitations under the License.\n*/\n\nimport { html, TemplateResult } from '@spectrum-web-components/base';\n\nimport '@spectrum-web-components/thumbnail/sp-thumbnail.js';\nimport { thumbnail as image } from './images.js';\n\nexport default {\n title: 'Thumbnail/Sizes',\n component: 'sp-thumbnail',\n};\n\nconst thumbnail = ({\n size,\n}: {\n size: 'xxs' | 'xs' | 's' | 'm' | 'l';\n}): TemplateResult => {\n return html`\n <sp-thumbnail size=${size}>\n <img src=${image} alt=\"Woman crouching\" />\n </sp-thumbnail>\n `;\n};\n\nexport const XXS = (): TemplateResult => thumbnail({ size: 'xxs' });\n\nexport const XS = (): TemplateResult => thumbnail({ size: 'xs' });\n\nexport const s = (): TemplateResult => thumbnail({ size: 's' });\n\nexport const m = (): TemplateResult => thumbnail({ size: 'm' });\n\nexport const l = (): TemplateResult => thumbnail({ size: 'l' });\n"],
|
|
5
|
-
"mappings": "AAYA
|
|
5
|
+
"mappings": "AAYA,qDAEA,2DACA,wCAEA,cAAe,CACX,MAAO,kBACP,UAAW,cACf,EAEA,KAAM,GAAY,CAAC,CACf,UAIO;AAAA,6BACkB;AAAA,uBACN;AAAA;AAAA,MAKhB,YAAM,KAAM,IAAsB,EAAU,CAAE,KAAM,KAAM,CAAC,EAErD,GAAK,IAAsB,EAAU,CAAE,KAAM,IAAK,CAAC,EAEnD,EAAI,IAAsB,EAAU,CAAE,KAAM,GAAI,CAAC,EAEjD,EAAI,IAAsB,EAAU,CAAE,KAAM,GAAI,CAAC,EAEjD,EAAI,IAAsB,EAAU,CAAE,KAAM,GAAI,CAAC",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,74 +1,40 @@
|
|
|
1
|
-
import
|
|
2
|
-
import "@spectrum-web-components/thumbnail/sp-thumbnail.js";
|
|
3
|
-
import {
|
|
4
|
-
landscape as landscapeImage,
|
|
5
|
-
portrait as portraitImage,
|
|
6
|
-
thumbnail
|
|
7
|
-
} from "./images.js";
|
|
8
|
-
export default {
|
|
9
|
-
title: "Thumbnail",
|
|
10
|
-
component: "sp-thumbnail"
|
|
11
|
-
};
|
|
12
|
-
export const Default = () => {
|
|
13
|
-
return html`
|
|
1
|
+
import{html as t}from"@spectrum-web-components/base";import"@spectrum-web-components/thumbnail/sp-thumbnail.js";import{landscape as a,portrait as n,thumbnail as e}from"./images.js";export default{title:"Thumbnail",component:"sp-thumbnail"};export const Default=()=>t`
|
|
14
2
|
<sp-thumbnail>
|
|
15
|
-
<img src=${
|
|
3
|
+
<img src=${e} alt="Woman crouching" />
|
|
16
4
|
</sp-thumbnail>
|
|
17
|
-
|
|
18
|
-
};
|
|
19
|
-
export const selected = () => {
|
|
20
|
-
return html`
|
|
5
|
+
`,selected=()=>t`
|
|
21
6
|
<sp-thumbnail selected>
|
|
22
|
-
<img src=${
|
|
7
|
+
<img src=${e} alt="Woman crouching" />
|
|
23
8
|
</sp-thumbnail>
|
|
24
|
-
|
|
25
|
-
};
|
|
26
|
-
export const focused = () => {
|
|
27
|
-
return html`
|
|
9
|
+
`,focused=()=>t`
|
|
28
10
|
<sp-thumbnail focused>
|
|
29
|
-
<img src=${
|
|
11
|
+
<img src=${e} alt="Woman crouching" />
|
|
30
12
|
</sp-thumbnail>
|
|
31
|
-
|
|
32
|
-
};
|
|
33
|
-
export const portrait = () => {
|
|
34
|
-
return html`
|
|
13
|
+
`,portrait=()=>t`
|
|
35
14
|
<sp-thumbnail>
|
|
36
|
-
<img src=${
|
|
15
|
+
<img src=${n} alt="Eiffel Tower at night" />
|
|
37
16
|
</sp-thumbnail>
|
|
38
|
-
|
|
39
|
-
};
|
|
40
|
-
export const landscape = () => {
|
|
41
|
-
return html`
|
|
17
|
+
`,landscape=()=>t`
|
|
42
18
|
<sp-thumbnail>
|
|
43
19
|
<img
|
|
44
|
-
src=${
|
|
20
|
+
src=${a}
|
|
45
21
|
alt="Landscape with mountains and lake"
|
|
46
22
|
/>
|
|
47
23
|
</sp-thumbnail>
|
|
48
|
-
|
|
49
|
-
};
|
|
50
|
-
export const portraitCover = () => {
|
|
51
|
-
return html`
|
|
24
|
+
`,portraitCover=()=>t`
|
|
52
25
|
<sp-thumbnail cover>
|
|
53
|
-
<img src=${
|
|
26
|
+
<img src=${n} alt="Eiffel Tower at night" />
|
|
54
27
|
</sp-thumbnail>
|
|
55
|
-
|
|
56
|
-
};
|
|
57
|
-
export const landscapeCover = () => {
|
|
58
|
-
return html`
|
|
28
|
+
`,landscapeCover=()=>t`
|
|
59
29
|
<sp-thumbnail cover>
|
|
60
30
|
<img
|
|
61
|
-
src=${
|
|
31
|
+
src=${a}
|
|
62
32
|
alt="Landscape with mountains and lake"
|
|
63
33
|
/>
|
|
64
34
|
</sp-thumbnail>
|
|
65
|
-
|
|
66
|
-
};
|
|
67
|
-
export const background = () => {
|
|
68
|
-
return html`
|
|
35
|
+
`,background=()=>t`
|
|
69
36
|
<sp-thumbnail background="orange">
|
|
70
|
-
<img src=${
|
|
37
|
+
<img src=${e} alt="Woman crouching" />
|
|
71
38
|
</sp-thumbnail>
|
|
72
39
|
`;
|
|
73
|
-
};
|
|
74
40
|
//# sourceMappingURL=thumbnail.stories.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["thumbnail.stories.ts"],
|
|
4
4
|
"sourcesContent": ["/*\nCopyright 2020 Adobe. All rights reserved.\nThis file is licensed to you under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License. You may obtain a copy\nof the License at http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software distributed under\nthe License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\nOF ANY KIND, either express or implied. See the License for the specific language\ngoverning permissions and limitations under the License.\n*/\n\nimport { html, TemplateResult } from '@spectrum-web-components/base';\n\nimport '@spectrum-web-components/thumbnail/sp-thumbnail.js';\nimport {\n landscape as landscapeImage,\n portrait as portraitImage,\n thumbnail,\n} from './images.js';\n\nexport default {\n title: 'Thumbnail',\n component: 'sp-thumbnail',\n};\n\nexport const Default = (): TemplateResult => {\n return html`\n <sp-thumbnail>\n <img src=${thumbnail} alt=\"Woman crouching\" />\n </sp-thumbnail>\n `;\n};\n\nexport const selected = (): TemplateResult => {\n return html`\n <sp-thumbnail selected>\n <img src=${thumbnail} alt=\"Woman crouching\" />\n </sp-thumbnail>\n `;\n};\n\nexport const focused = (): TemplateResult => {\n return html`\n <sp-thumbnail focused>\n <img src=${thumbnail} alt=\"Woman crouching\" />\n </sp-thumbnail>\n `;\n};\n\nexport const portrait = (): TemplateResult => {\n return html`\n <sp-thumbnail>\n <img src=${portraitImage} alt=\"Eiffel Tower at night\" />\n </sp-thumbnail>\n `;\n};\n\nexport const landscape = (): TemplateResult => {\n return html`\n <sp-thumbnail>\n <img\n src=${landscapeImage}\n alt=\"Landscape with mountains and lake\"\n />\n </sp-thumbnail>\n `;\n};\n\nexport const portraitCover = (): TemplateResult => {\n return html`\n <sp-thumbnail cover>\n <img src=${portraitImage} alt=\"Eiffel Tower at night\" />\n </sp-thumbnail>\n `;\n};\n\nexport const landscapeCover = (): TemplateResult => {\n return html`\n <sp-thumbnail cover>\n <img\n src=${landscapeImage}\n alt=\"Landscape with mountains and lake\"\n />\n </sp-thumbnail>\n `;\n};\n\nexport const background = (): TemplateResult => {\n return html`\n <sp-thumbnail background=\"orange\">\n <img src=${thumbnail} alt=\"Woman crouching\" />\n </sp-thumbnail>\n `;\n};\n"],
|
|
5
|
-
"mappings": "AAYA
|
|
5
|
+
"mappings": "AAYA,qDAEA,2DACA,qEAMA,cAAe,CACX,MAAO,YACP,UAAW,cACf,EAEO,YAAM,SAAU,IACZ;AAAA;AAAA,uBAEY;AAAA;AAAA,MAKV,SAAW,IACb;AAAA;AAAA,uBAEY;AAAA;AAAA,MAKV,QAAU,IACZ;AAAA;AAAA,uBAEY;AAAA;AAAA,MAKV,SAAW,IACb;AAAA;AAAA,uBAEY;AAAA;AAAA,MAKV,UAAY,IACd;AAAA;AAAA;AAAA,sBAGW;AAAA;AAAA;AAAA;AAAA,MAOT,cAAgB,IAClB;AAAA;AAAA,uBAEY;AAAA;AAAA,MAKV,eAAiB,IACnB;AAAA;AAAA;AAAA,sBAGW;AAAA;AAAA;AAAA;AAAA,MAOT,WAAa,IACf;AAAA;AAAA,uBAEY;AAAA;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,10 +1,6 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { html } from "lit";
|
|
3
|
-
import { measureFixtureCreation } from "../../../../test/benchmark/helpers.js";
|
|
4
|
-
import { thumbnail } from "../../stories/images.js";
|
|
5
|
-
measureFixtureCreation(html`
|
|
1
|
+
import"@spectrum-web-components/thumbnail/sp-thumbnail.js";import{html as m}from"lit";import{measureFixtureCreation as r}from"../../../../test/benchmark/helpers.js";import{thumbnail as i}from"../../stories/images.js";r(m`
|
|
6
2
|
<sp-thumbnail>
|
|
7
|
-
<img src=${
|
|
3
|
+
<img src=${i} alt="Woman crouching" />
|
|
8
4
|
</sp-thumbnail>
|
|
9
5
|
`);
|
|
10
6
|
//# sourceMappingURL=basic-test.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["basic-test.ts"],
|
|
4
4
|
"sourcesContent": ["/*\nCopyright 2020 Adobe. All rights reserved.\nThis file is licensed to you under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License. You may obtain a copy\nof the License at http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software distributed under\nthe License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\nOF ANY KIND, either express or implied. See the License for the specific language\ngoverning permissions and limitations under the License.\n*/\n\nimport '@spectrum-web-components/thumbnail/sp-thumbnail.js';\nimport { html } from 'lit';\nimport { measureFixtureCreation } from '../../../../test/benchmark/helpers.js';\nimport { thumbnail } from '../../stories/images.js';\n\nmeasureFixtureCreation(html`\n <sp-thumbnail>\n <img src=${thumbnail} alt=\"Woman crouching\" />\n </sp-thumbnail>\n`);\n"],
|
|
5
|
-
"mappings": "AAYA
|
|
5
|
+
"mappings": "AAYA,2DACA,2BACA,+EACA,oDAEA,EAAuB;AAAA;AAAA,mBAEJ;AAAA;AAAA,CAElB",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,4 +1,2 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { regressVisuals } from "../../../test/visual/test.js";
|
|
3
|
-
regressVisuals("ThumbnailSizesStories", stories);
|
|
1
|
+
import*as s from"../stories/thumbnail-sizes.stories.js";import{regressVisuals as r}from"../../../test/visual/test.js";r("ThumbnailSizesStories",s);
|
|
4
2
|
//# sourceMappingURL=thumbnail-sizes.test-vrt.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["thumbnail-sizes.test-vrt.ts"],
|
|
4
4
|
"sourcesContent": ["/*\nCopyright 2020 Adobe. All rights reserved.\nThis file is licensed to you under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License. You may obtain a copy\nof the License at http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software distributed under\nthe License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\nOF ANY KIND, either express or implied. See the License for the specific language\ngoverning permissions and limitations under the License.\n*/\n\nimport * as stories from '../stories/thumbnail-sizes.stories.js';\nimport { regressVisuals } from '../../../test/visual/test.js';\n\nregressVisuals('ThumbnailSizesStories', stories);\n"],
|
|
5
|
-
"mappings": "AAYA
|
|
5
|
+
"mappings": "AAYA,wDACA,8DAEA,EAAe,wBAAyB,CAAO",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,4 +1,2 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { regressVisuals } from "../../../test/visual/test.js";
|
|
3
|
-
regressVisuals("ThumbnailStories", stories);
|
|
1
|
+
import*as r from"../stories/thumbnail.stories.js";import{regressVisuals as s}from"../../../test/visual/test.js";s("ThumbnailStories",r);
|
|
4
2
|
//# sourceMappingURL=thumbnail.test-vrt.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["thumbnail.test-vrt.ts"],
|
|
4
4
|
"sourcesContent": ["/*\nCopyright 2020 Adobe. All rights reserved.\nThis file is licensed to you under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License. You may obtain a copy\nof the License at http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software distributed under\nthe License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\nOF ANY KIND, either express or implied. See the License for the specific language\ngoverning permissions and limitations under the License.\n*/\n\nimport * as stories from '../stories/thumbnail.stories.js';\nimport { regressVisuals } from '../../../test/visual/test.js';\n\nregressVisuals('ThumbnailStories', stories);\n"],
|
|
5
|
-
"mappings": "AAYA
|
|
5
|
+
"mappings": "AAYA,kDACA,8DAEA,EAAe,mBAAoB,CAAO",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/test/thumbnail.test.js
CHANGED
|
@@ -1,39 +1,18 @@
|
|
|
1
|
-
import
|
|
2
|
-
import "../sp-thumbnail.js";
|
|
3
|
-
import { thumbnail } from "../stories/images.js";
|
|
4
|
-
import { testForLitDevWarnings } from "../../../test/testing-helpers.js";
|
|
5
|
-
describe("Thumbnail", () => {
|
|
6
|
-
testForLitDevWarnings(async () => await fixture(html`
|
|
1
|
+
import{elementUpdated as l,expect as s,fixture as t,html as i}from"@open-wc/testing";import"../sp-thumbnail.js";import{thumbnail as n}from"../stories/images.js";import{testForLitDevWarnings as o}from"../../../test/testing-helpers.js";describe("Thumbnail",()=>{o(async()=>await t(i`
|
|
7
2
|
<sp-thumbnail>
|
|
8
|
-
<img src=${
|
|
3
|
+
<img src=${n} alt="Woman crouching" />
|
|
9
4
|
</sp-thumbnail>
|
|
10
|
-
`))
|
|
11
|
-
it("loads default thumbnail accessibly", async () => {
|
|
12
|
-
const el = await fixture(html`
|
|
5
|
+
`)),it("loads default thumbnail accessibly",async()=>{const a=await t(i`
|
|
13
6
|
<sp-thumbnail>
|
|
14
|
-
<img src=${
|
|
7
|
+
<img src=${n} alt="Woman crouching" />
|
|
15
8
|
</sp-thumbnail>
|
|
16
|
-
`);
|
|
17
|
-
await elementUpdated(el);
|
|
18
|
-
await expect(el).to.be.accessible();
|
|
19
|
-
});
|
|
20
|
-
it("can be size `xxs`", async () => {
|
|
21
|
-
const el = await fixture(html`
|
|
9
|
+
`);await l(a),await s(a).to.be.accessible()}),it("can be size `xxs`",async()=>{const a=await t(i`
|
|
22
10
|
<sp-thumbnail size="xxs">
|
|
23
|
-
<img src=${
|
|
11
|
+
<img src=${n} alt="Woman crouching" />
|
|
24
12
|
</sp-thumbnail>
|
|
25
|
-
`);
|
|
26
|
-
await elementUpdated(el);
|
|
27
|
-
expect(el.size).to.equal("xxs");
|
|
28
|
-
});
|
|
29
|
-
it("accepts `background`", async () => {
|
|
30
|
-
const el = await fixture(html`
|
|
13
|
+
`);await l(a),s(a.size).to.equal("xxs")}),it("accepts `background`",async()=>{const m=(await t(i`
|
|
31
14
|
<sp-thumbnail background="blue">
|
|
32
|
-
<img src=${
|
|
15
|
+
<img src=${n} alt="Woman crouching" />
|
|
33
16
|
</sp-thumbnail>
|
|
34
|
-
`);
|
|
35
|
-
const background = el.shadowRoot.querySelector(".background");
|
|
36
|
-
expect(background).to.not.be.null;
|
|
37
|
-
});
|
|
38
|
-
});
|
|
17
|
+
`)).shadowRoot.querySelector(".background");s(m).to.not.be.null})});
|
|
39
18
|
//# sourceMappingURL=thumbnail.test.js.map
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["thumbnail.test.ts"],
|
|
4
4
|
"sourcesContent": ["/*\nCopyright 2020 Adobe. All rights reserved.\nThis file is licensed to you under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License. You may obtain a copy\nof the License at http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software distributed under\nthe License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\nOF ANY KIND, either express or implied. See the License for the specific language\ngoverning permissions and limitations under the License.\n*/\n\nimport { elementUpdated, expect, fixture, html } from '@open-wc/testing';\n\nimport '../sp-thumbnail.js';\nimport { Thumbnail } from '..';\nimport { thumbnail } from '../stories/images.js';\nimport { testForLitDevWarnings } from '../../../test/testing-helpers.js';\n\ndescribe('Thumbnail', () => {\n testForLitDevWarnings(\n async () =>\n await fixture<Thumbnail>(\n html`\n <sp-thumbnail>\n <img src=${thumbnail} alt=\"Woman crouching\" />\n </sp-thumbnail>\n `\n )\n );\n it('loads default thumbnail accessibly', async () => {\n const el = await fixture<Thumbnail>(\n html`\n <sp-thumbnail>\n <img src=${thumbnail} alt=\"Woman crouching\" />\n </sp-thumbnail>\n `\n );\n\n await elementUpdated(el);\n\n await expect(el).to.be.accessible();\n });\n it('can be size `xxs`', async () => {\n const el = await fixture<Thumbnail>(\n html`\n <sp-thumbnail size=\"xxs\">\n <img src=${thumbnail} alt=\"Woman crouching\" />\n </sp-thumbnail>\n `\n );\n\n await elementUpdated(el);\n\n expect(el.size).to.equal('xxs');\n });\n it('accepts `background`', async () => {\n const el = await fixture<Thumbnail>(\n html`\n <sp-thumbnail background=\"blue\">\n <img src=${thumbnail} alt=\"Woman crouching\" />\n </sp-thumbnail>\n `\n );\n\n const background = el.shadowRoot.querySelector('.background');\n expect(background).to.not.be.null;\n });\n});\n"],
|
|
5
|
-
"mappings": "AAYA
|
|
5
|
+
"mappings": "AAYA,qFAEA,2BAEA,iDACA,yEAEA,SAAS,YAAa,IAAM,CACxB,EACI,SACI,KAAM,GACF;AAAA;AAAA,mCAEmB;AAAA;AAAA,iBAGvB,CACR,EACA,GAAG,qCAAsC,SAAY,CACjD,KAAM,GAAK,KAAM,GACb;AAAA;AAAA,+BAEmB;AAAA;AAAA,aAGvB,EAEA,KAAM,GAAe,CAAE,EAEvB,KAAM,GAAO,CAAE,EAAE,GAAG,GAAG,WAAW,CACtC,CAAC,EACD,GAAG,oBAAqB,SAAY,CAChC,KAAM,GAAK,KAAM,GACb;AAAA;AAAA,+BAEmB;AAAA;AAAA,aAGvB,EAEA,KAAM,GAAe,CAAE,EAEvB,EAAO,EAAG,IAAI,EAAE,GAAG,MAAM,KAAK,CAClC,CAAC,EACD,GAAG,uBAAwB,SAAY,CASnC,KAAM,GAAa,AARR,MAAM,GACb;AAAA;AAAA,+BAEmB;AAAA;AAAA,aAGvB,GAEsB,WAAW,cAAc,aAAa,EAC5D,EAAO,CAAU,EAAE,GAAG,IAAI,GAAG,IACjC,CAAC,CACL,CAAC",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|