@spectrum-web-components/tabs 0.8.13 → 0.8.15-devmode.7
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 +41 -14
- package/sp-tab-panel.dev.js +3 -0
- package/sp-tab-panel.dev.js.map +7 -0
- package/sp-tab-panel.js +3 -14
- package/sp-tab-panel.js.map +7 -1
- package/sp-tab.dev.js +3 -0
- package/sp-tab.dev.js.map +7 -0
- package/sp-tab.js +3 -14
- package/sp-tab.js.map +7 -1
- package/sp-tabs.dev.js +3 -0
- package/sp-tabs.dev.js.map +7 -0
- package/sp-tabs.js +3 -14
- package/sp-tabs.js.map +7 -1
- package/src/Tab.dev.js +101 -0
- package/src/Tab.dev.js.map +7 -0
- package/src/Tab.js +92 -103
- package/src/Tab.js.map +7 -1
- package/src/TabPanel.dev.js +58 -0
- package/src/TabPanel.dev.js.map +7 -0
- package/src/TabPanel.js +51 -57
- package/src/TabPanel.js.map +7 -1
- package/src/Tabs.dev.js +304 -0
- package/src/Tabs.dev.js.map +7 -0
- package/src/Tabs.js +275 -302
- package/src/Tabs.js.map +7 -1
- package/src/index.dev.js +4 -0
- package/src/index.dev.js.map +7 -0
- package/src/index.js +4 -15
- package/src/index.js.map +7 -1
- package/src/spectrum-tab.css.dev.js +40 -0
- package/src/spectrum-tab.css.dev.js.map +7 -0
- package/src/spectrum-tab.css.js +3 -14
- package/src/spectrum-tab.css.js.map +7 -1
- package/src/spectrum-tabs.css.dev.js +392 -0
- package/src/spectrum-tabs.css.dev.js.map +7 -0
- package/src/spectrum-tabs.css.js +3 -14
- package/src/spectrum-tabs.css.js.map +7 -1
- package/src/tab-panel.css.dev.js +6 -0
- package/src/tab-panel.css.dev.js.map +7 -0
- package/src/tab-panel.css.js +3 -14
- package/src/tab-panel.css.js.map +7 -1
- package/src/tab.css.dev.js +54 -0
- package/src/tab.css.dev.js.map +7 -0
- package/src/tab.css.js +3 -14
- package/src/tab.css.js.map +7 -1
- package/src/tabs.css.dev.js +406 -0
- package/src/tabs.css.dev.js.map +7 -0
- package/src/tabs.css.js +3 -14
- package/src/tabs.css.js.map +7 -1
- package/stories/tabs-horizontal-sizes.stories.js +53 -64
- package/stories/tabs-horizontal-sizes.stories.js.map +7 -1
- package/stories/tabs-vertical-right-sizes.stories.js +50 -61
- package/stories/tabs-vertical-right-sizes.stories.js.map +7 -1
- package/stories/tabs-vertical-sizes.stories.js +50 -61
- package/stories/tabs-vertical-sizes.stories.js.map +7 -1
- package/stories/tabs.stories.js +79 -81
- package/stories/tabs.stories.js.map +7 -1
- package/test/benchmark/basic-test.js +6 -17
- package/test/benchmark/basic-test.js.map +7 -1
- package/test/tab.test.js +21 -34
- package/test/tab.test.js.map +7 -1
- package/test/tabs-horizontal-sizes.test-vrt.js +4 -15
- package/test/tabs-horizontal-sizes.test-vrt.js.map +7 -1
- package/test/tabs-vertical-right-sizes.test-vrt.js +4 -15
- package/test/tabs-vertical-right-sizes.test-vrt.js.map +7 -1
- package/test/tabs-vertical-sizes.test-vrt.js +4 -15
- package/test/tabs-vertical-sizes.test-vrt.js.map +7 -1
- package/test/tabs.test-vrt.js +4 -15
- package/test/tabs.test-vrt.js.map +7 -1
- package/test/tabs.test.js +375 -383
- package/test/tabs.test.js.map +7 -1
package/test/tab.test.js
CHANGED
|
@@ -1,43 +1,30 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
|
|
9
|
-
OF ANY KIND, either express or implied. See the License for the specific language
|
|
10
|
-
governing permissions and limitations under the License.
|
|
11
|
-
*/
|
|
12
|
-
import '../sp-tabs.js';
|
|
13
|
-
import '../sp-tab.js';
|
|
14
|
-
import { elementUpdated, expect, fixture } from '@open-wc/testing';
|
|
15
|
-
import { html } from 'lit/static-html.js';
|
|
16
|
-
describe('Tab', () => {
|
|
17
|
-
it('loads default tab accessibly', async () => {
|
|
18
|
-
const el = await fixture(html `
|
|
1
|
+
import "@spectrum-web-components/tabs/sp-tabs.js";
|
|
2
|
+
import "@spectrum-web-components/tabs/sp-tab.js";
|
|
3
|
+
import { elementUpdated, expect, fixture } from "@open-wc/testing";
|
|
4
|
+
import { html } from "lit/static-html.js";
|
|
5
|
+
describe("Tab", () => {
|
|
6
|
+
it("loads default tab accessibly", async () => {
|
|
7
|
+
const el = await fixture(html`
|
|
19
8
|
<sp-tabs>
|
|
20
9
|
<sp-tab label="Tab 1" value="first"></sp-tab>
|
|
21
10
|
</sp-tabs>
|
|
22
11
|
`);
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
12
|
+
await elementUpdated(el);
|
|
13
|
+
await expect(el).to.be.accessible();
|
|
14
|
+
});
|
|
15
|
+
it("Updates label", async () => {
|
|
16
|
+
const el = await fixture(html`
|
|
28
17
|
<sp-tabs>
|
|
29
18
|
<sp-tab label="Tab 1" value="first"></sp-tab>
|
|
30
19
|
</sp-tabs>
|
|
31
20
|
`);
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
expect(label.textContent).to.include('Other Tab');
|
|
41
|
-
});
|
|
21
|
+
await elementUpdated(el);
|
|
22
|
+
const firstTab = el.querySelector("sp-tab");
|
|
23
|
+
const label = firstTab.shadowRoot ? firstTab.shadowRoot.querySelector("#item-label") : firstTab.querySelector("#itemLabel");
|
|
24
|
+
expect(label.textContent).to.include("Tab 1");
|
|
25
|
+
firstTab.label = "Other Tab";
|
|
26
|
+
await elementUpdated(firstTab);
|
|
27
|
+
expect(label.textContent).to.include("Other Tab");
|
|
28
|
+
});
|
|
42
29
|
});
|
|
43
|
-
//# sourceMappingURL=tab.test.js.map
|
|
30
|
+
//# sourceMappingURL=tab.test.js.map
|
package/test/tab.test.js.map
CHANGED
|
@@ -1 +1,7 @@
|
|
|
1
|
-
{
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["tab.test.ts"],
|
|
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*/\nimport '@spectrum-web-components/tabs/sp-tabs.js';\nimport '@spectrum-web-components/tabs/sp-tab.js';\nimport { Tab, Tabs } from '@spectrum-web-components/tabs';\nimport { elementUpdated, expect, fixture } from '@open-wc/testing';\nimport { html } from 'lit/static-html.js';\n\ndescribe('Tab', () => {\n it('loads default tab accessibly', async () => {\n const el = await fixture<Tabs>(\n html`\n <sp-tabs>\n <sp-tab label=\"Tab 1\" value=\"first\"></sp-tab>\n </sp-tabs>\n `\n );\n\n await elementUpdated(el);\n\n await expect(el).to.be.accessible();\n });\n it('Updates label', async () => {\n const el = await fixture<Tabs>(\n html`\n <sp-tabs>\n <sp-tab label=\"Tab 1\" value=\"first\"></sp-tab>\n </sp-tabs>\n `\n );\n\n await elementUpdated(el);\n const firstTab = el.querySelector('sp-tab') as Tab;\n const label = firstTab.shadowRoot\n ? (firstTab.shadowRoot.querySelector(\n '#item-label'\n ) as HTMLLabelElement)\n : (firstTab.querySelector('#itemLabel') as HTMLLabelElement);\n expect(label.textContent).to.include('Tab 1');\n\n firstTab.label = 'Other Tab';\n\n await elementUpdated(firstTab);\n expect(label.textContent).to.include('Other Tab');\n });\n});\n"],
|
|
5
|
+
"mappings": "AAWA;AACA;AAEA;AACA;AAEA,SAAS,OAAO,MAAM;AAClB,KAAG,gCAAgC,YAAY;AAC3C,UAAM,KAAK,MAAM,QACb;AAAA;AAAA;AAAA;AAAA,aAKJ;AAEA,UAAM,eAAe,EAAE;AAEvB,UAAM,OAAO,EAAE,EAAE,GAAG,GAAG,WAAW;AAAA,EACtC,CAAC;AACD,KAAG,iBAAiB,YAAY;AAC5B,UAAM,KAAK,MAAM,QACb;AAAA;AAAA;AAAA;AAAA,aAKJ;AAEA,UAAM,eAAe,EAAE;AACvB,UAAM,WAAW,GAAG,cAAc,QAAQ;AAC1C,UAAM,QAAQ,SAAS,aAChB,SAAS,WAAW,cACjB,aACJ,IACC,SAAS,cAAc,YAAY;AAC1C,WAAO,MAAM,WAAW,EAAE,GAAG,QAAQ,OAAO;AAE5C,aAAS,QAAQ;AAEjB,UAAM,eAAe,QAAQ;AAC7B,WAAO,MAAM,WAAW,EAAE,GAAG,QAAQ,WAAW;AAAA,EACpD,CAAC;AACL,CAAC;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -1,15 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
of the License at http://www.apache.org/licenses/LICENSE-2.0
|
|
6
|
-
|
|
7
|
-
Unless required by applicable law or agreed to in writing, software distributed under
|
|
8
|
-
the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
|
|
9
|
-
OF ANY KIND, either express or implied. See the License for the specific language
|
|
10
|
-
governing permissions and limitations under the License.
|
|
11
|
-
*/
|
|
12
|
-
import * as stories from '../stories/tabs-horizontal-sizes.stories.js';
|
|
13
|
-
import { regressVisuals } from '../../../test/visual/test.js';
|
|
14
|
-
regressVisuals('TabsHorizontalSizesStories', stories);
|
|
15
|
-
//# sourceMappingURL=tabs-horizontal-sizes.test-vrt.js.map
|
|
1
|
+
import * as stories from "../stories/tabs-horizontal-sizes.stories.js";
|
|
2
|
+
import { regressVisuals } from "../../../test/visual/test.js";
|
|
3
|
+
regressVisuals("TabsHorizontalSizesStories", stories);
|
|
4
|
+
//# sourceMappingURL=tabs-horizontal-sizes.test-vrt.js.map
|
|
@@ -1 +1,7 @@
|
|
|
1
|
-
{
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["tabs-horizontal-sizes.test-vrt.ts"],
|
|
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/tabs-horizontal-sizes.stories.js';\nimport { regressVisuals } from '../../../test/visual/test.js';\n\nregressVisuals('TabsHorizontalSizesStories', stories);\n"],
|
|
5
|
+
"mappings": "AAYA;AACA;AAEA,eAAe,8BAA8B,OAAO;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -1,15 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
of the License at http://www.apache.org/licenses/LICENSE-2.0
|
|
6
|
-
|
|
7
|
-
Unless required by applicable law or agreed to in writing, software distributed under
|
|
8
|
-
the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
|
|
9
|
-
OF ANY KIND, either express or implied. See the License for the specific language
|
|
10
|
-
governing permissions and limitations under the License.
|
|
11
|
-
*/
|
|
12
|
-
import * as stories from '../stories/tabs-vertical-right-sizes.stories.js';
|
|
13
|
-
import { regressVisuals } from '../../../test/visual/test.js';
|
|
14
|
-
regressVisuals('TabsVerticalRightSizesStories', stories);
|
|
15
|
-
//# sourceMappingURL=tabs-vertical-right-sizes.test-vrt.js.map
|
|
1
|
+
import * as stories from "../stories/tabs-vertical-right-sizes.stories.js";
|
|
2
|
+
import { regressVisuals } from "../../../test/visual/test.js";
|
|
3
|
+
regressVisuals("TabsVerticalRightSizesStories", stories);
|
|
4
|
+
//# sourceMappingURL=tabs-vertical-right-sizes.test-vrt.js.map
|
|
@@ -1 +1,7 @@
|
|
|
1
|
-
{
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["tabs-vertical-right-sizes.test-vrt.ts"],
|
|
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/tabs-vertical-right-sizes.stories.js';\nimport { regressVisuals } from '../../../test/visual/test.js';\n\nregressVisuals('TabsVerticalRightSizesStories', stories);\n"],
|
|
5
|
+
"mappings": "AAYA;AACA;AAEA,eAAe,iCAAiC,OAAO;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -1,15 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
of the License at http://www.apache.org/licenses/LICENSE-2.0
|
|
6
|
-
|
|
7
|
-
Unless required by applicable law or agreed to in writing, software distributed under
|
|
8
|
-
the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
|
|
9
|
-
OF ANY KIND, either express or implied. See the License for the specific language
|
|
10
|
-
governing permissions and limitations under the License.
|
|
11
|
-
*/
|
|
12
|
-
import * as stories from '../stories/tabs-vertical-sizes.stories.js';
|
|
13
|
-
import { regressVisuals } from '../../../test/visual/test.js';
|
|
14
|
-
regressVisuals('TabsVerticalSizesStories', stories);
|
|
15
|
-
//# sourceMappingURL=tabs-vertical-sizes.test-vrt.js.map
|
|
1
|
+
import * as stories from "../stories/tabs-vertical-sizes.stories.js";
|
|
2
|
+
import { regressVisuals } from "../../../test/visual/test.js";
|
|
3
|
+
regressVisuals("TabsVerticalSizesStories", stories);
|
|
4
|
+
//# sourceMappingURL=tabs-vertical-sizes.test-vrt.js.map
|
|
@@ -1 +1,7 @@
|
|
|
1
|
-
{
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["tabs-vertical-sizes.test-vrt.ts"],
|
|
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/tabs-vertical-sizes.stories.js';\nimport { regressVisuals } from '../../../test/visual/test.js';\n\nregressVisuals('TabsVerticalSizesStories', stories);\n"],
|
|
5
|
+
"mappings": "AAYA;AACA;AAEA,eAAe,4BAA4B,OAAO;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
package/test/tabs.test-vrt.js
CHANGED
|
@@ -1,15 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
of the License at http://www.apache.org/licenses/LICENSE-2.0
|
|
6
|
-
|
|
7
|
-
Unless required by applicable law or agreed to in writing, software distributed under
|
|
8
|
-
the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
|
|
9
|
-
OF ANY KIND, either express or implied. See the License for the specific language
|
|
10
|
-
governing permissions and limitations under the License.
|
|
11
|
-
*/
|
|
12
|
-
import * as stories from '../stories/tabs.stories.js';
|
|
13
|
-
import { regressVisuals } from '../../../test/visual/test.js';
|
|
14
|
-
regressVisuals('TabsStories', stories);
|
|
15
|
-
//# sourceMappingURL=tabs.test-vrt.js.map
|
|
1
|
+
import * as stories from "../stories/tabs.stories.js";
|
|
2
|
+
import { regressVisuals } from "../../../test/visual/test.js";
|
|
3
|
+
regressVisuals("TabsStories", stories);
|
|
4
|
+
//# sourceMappingURL=tabs.test-vrt.js.map
|
|
@@ -1 +1,7 @@
|
|
|
1
|
-
{
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["tabs.test-vrt.ts"],
|
|
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/tabs.stories.js';\nimport { regressVisuals } from '../../../test/visual/test.js';\n\nregressVisuals('TabsStories', stories);\n"],
|
|
5
|
+
"mappings": "AAYA;AACA;AAEA,eAAe,eAAe,OAAO;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|