@spectrum-web-components/popover 1.0.0-rc.1 → 1.0.0-rc.2

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@spectrum-web-components/popover",
3
- "version": "1.0.0-rc.1",
3
+ "version": "1.0.0-rc.2",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -58,8 +58,8 @@
58
58
  "lit-html"
59
59
  ],
60
60
  "dependencies": {
61
- "@spectrum-web-components/base": "^1.0.0-rc.1",
62
- "@spectrum-web-components/overlay": "^1.0.0-rc.1"
61
+ "@spectrum-web-components/base": "^1.0.0-rc.2",
62
+ "@spectrum-web-components/overlay": "^1.0.0-rc.2"
63
63
  },
64
64
  "devDependencies": {
65
65
  "@spectrum-css/popover": "^8.0.0-s2-foundations.16"
@@ -70,5 +70,5 @@
70
70
  "./sp-*.js",
71
71
  "./**/*.dev.js"
72
72
  ],
73
- "gitHead": "9f2638a0500c33adc8e06079a87a55b7d5695966"
73
+ "gitHead": "45ad539f37a4325a83d02253ea9135c90e1b8b3d"
74
74
  }
@@ -19,8 +19,9 @@ describe("popover", () => {
19
19
  await elementUpdated(popover);
20
20
  });
21
21
  it("loads", async () => {
22
+ var _a;
22
23
  expect(popover).to.not.equal(void 0);
23
- expect(popover.textContent).to.include("Popover Title");
24
+ expect((_a = popover.textContent) == null ? void 0 : _a.trim()).to.include("Popover title");
24
25
  await expect(popover).to.be.accessible();
25
26
  });
26
27
  it("tip exists only when tip attribute is true", async () => {
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["popover.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/popover/sp-popover.js';\nimport '@spectrum-web-components/dialog/sp-dialog.js';\nimport { Popover } from '@spectrum-web-components/popover';\nimport { elementUpdated, expect, fixture, html } from '@open-wc/testing';\n\ndescribe('popover', () => {\n let popover!: Popover;\n\n beforeEach(async () => {\n popover = await fixture<Popover>(html`\n <sp-popover placement=\"top\" open>\n <sp-dialog>\n <h3 slot=\"heading\">Popover title</h3>\n Cupcake ipsum dolor sit amet jelly beans. Chocolate jelly\n caramels. Icing souffl\u00E9 chupa chups donut cheesecake.\n Jelly-o chocolate cake sweet roll cake danish candy biscuit\n halvah\n </sp-dialog>\n </sp-popover>\n `);\n await elementUpdated(popover);\n });\n\n it('loads', async () => {\n expect(popover).to.not.equal(undefined);\n expect(popover.textContent).to.include('Popover Title');\n\n await expect(popover).to.be.accessible();\n });\n it('tip exists only when tip attribute is true', async () => {\n if (!popover.shadowRoot) throw new Error('No shadowRoot');\n expect(popover.getAttribute('tip')).to.equal(null);\n\n let tip = popover.shadowRoot.querySelector('tip') as HTMLElement;\n expect(tip).to.equal(null);\n\n popover.setAttribute('tip', 'true');\n\n tip = popover.shadowRoot.querySelector('tip') as HTMLElement;\n expect(tip).to.not.equal(undefined);\n });\n\n it('surfaces tip element', async () => {\n const el = await fixture<Popover>(html`\n <sp-popover placement=\"top\" tip open>\n <div id=\"title\">Popover Title</div>\n <div id=\"content\">\n Cupcake ipsum dolor sit amet jelly beans. Chocolate jelly\n caramels. Icing souffl\u00E9 chupa chups donut cheesecake.\n Jelly-o chocolate cake sweet roll cake danish candy biscuit\n halvah\n </div>\n </sp-popover>\n `);\n\n await elementUpdated(el);\n\n expect(typeof el.tipElement).to.not.equal('undefined');\n });\n});\n"],
5
- "mappings": ";AAWA,OAAO;AACP,OAAO;AAEP,SAAS,gBAAgB,QAAQ,SAAS,YAAY;AAEtD,SAAS,WAAW,MAAM;AACtB,MAAI;AAEJ,aAAW,YAAY;AACnB,cAAU,MAAM,QAAiB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,SAUhC;AACD,UAAM,eAAe,OAAO;AAAA,EAChC,CAAC;AAED,KAAG,SAAS,YAAY;AACpB,WAAO,OAAO,EAAE,GAAG,IAAI,MAAM,MAAS;AACtC,WAAO,QAAQ,WAAW,EAAE,GAAG,QAAQ,eAAe;AAEtD,UAAM,OAAO,OAAO,EAAE,GAAG,GAAG,WAAW;AAAA,EAC3C,CAAC;AACD,KAAG,8CAA8C,YAAY;AACzD,QAAI,CAAC,QAAQ,WAAY,OAAM,IAAI,MAAM,eAAe;AACxD,WAAO,QAAQ,aAAa,KAAK,CAAC,EAAE,GAAG,MAAM,IAAI;AAEjD,QAAI,MAAM,QAAQ,WAAW,cAAc,KAAK;AAChD,WAAO,GAAG,EAAE,GAAG,MAAM,IAAI;AAEzB,YAAQ,aAAa,OAAO,MAAM;AAElC,UAAM,QAAQ,WAAW,cAAc,KAAK;AAC5C,WAAO,GAAG,EAAE,GAAG,IAAI,MAAM,MAAS;AAAA,EACtC,CAAC;AAED,KAAG,wBAAwB,YAAY;AACnC,UAAM,KAAK,MAAM,QAAiB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,SAUjC;AAED,UAAM,eAAe,EAAE;AAEvB,WAAO,OAAO,GAAG,UAAU,EAAE,GAAG,IAAI,MAAM,WAAW;AAAA,EACzD,CAAC;AACL,CAAC;",
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/popover/sp-popover.js';\nimport '@spectrum-web-components/dialog/sp-dialog.js';\nimport { Popover } from '@spectrum-web-components/popover';\nimport { elementUpdated, expect, fixture, html } from '@open-wc/testing';\n\ndescribe('popover', () => {\n let popover!: Popover;\n\n beforeEach(async () => {\n popover = await fixture<Popover>(html`\n <sp-popover placement=\"top\" open>\n <sp-dialog>\n <h3 slot=\"heading\">Popover title</h3>\n Cupcake ipsum dolor sit amet jelly beans. Chocolate jelly\n caramels. Icing souffl\u00E9 chupa chups donut cheesecake.\n Jelly-o chocolate cake sweet roll cake danish candy biscuit\n halvah\n </sp-dialog>\n </sp-popover>\n `);\n await elementUpdated(popover);\n });\n\n it('loads', async () => {\n expect(popover).to.not.equal(undefined);\n expect(popover.textContent?.trim()).to.include('Popover title');\n\n await expect(popover).to.be.accessible();\n });\n it('tip exists only when tip attribute is true', async () => {\n if (!popover.shadowRoot) throw new Error('No shadowRoot');\n expect(popover.getAttribute('tip')).to.equal(null);\n\n let tip = popover.shadowRoot.querySelector('tip') as HTMLElement;\n expect(tip).to.equal(null);\n\n popover.setAttribute('tip', 'true');\n\n tip = popover.shadowRoot.querySelector('tip') as HTMLElement;\n expect(tip).to.not.equal(undefined);\n });\n\n it('surfaces tip element', async () => {\n const el = await fixture<Popover>(html`\n <sp-popover placement=\"top\" tip open>\n <div id=\"title\">Popover Title</div>\n <div id=\"content\">\n Cupcake ipsum dolor sit amet jelly beans. Chocolate jelly\n caramels. Icing souffl\u00E9 chupa chups donut cheesecake.\n Jelly-o chocolate cake sweet roll cake danish candy biscuit\n halvah\n </div>\n </sp-popover>\n `);\n\n await elementUpdated(el);\n\n expect(typeof el.tipElement).to.not.equal('undefined');\n });\n});\n"],
5
+ "mappings": ";AAWA,OAAO;AACP,OAAO;AAEP,SAAS,gBAAgB,QAAQ,SAAS,YAAY;AAEtD,SAAS,WAAW,MAAM;AACtB,MAAI;AAEJ,aAAW,YAAY;AACnB,cAAU,MAAM,QAAiB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,SAUhC;AACD,UAAM,eAAe,OAAO;AAAA,EAChC,CAAC;AAED,KAAG,SAAS,YAAY;AAlC5B;AAmCQ,WAAO,OAAO,EAAE,GAAG,IAAI,MAAM,MAAS;AACtC,YAAO,aAAQ,gBAAR,mBAAqB,MAAM,EAAE,GAAG,QAAQ,eAAe;AAE9D,UAAM,OAAO,OAAO,EAAE,GAAG,GAAG,WAAW;AAAA,EAC3C,CAAC;AACD,KAAG,8CAA8C,YAAY;AACzD,QAAI,CAAC,QAAQ,WAAY,OAAM,IAAI,MAAM,eAAe;AACxD,WAAO,QAAQ,aAAa,KAAK,CAAC,EAAE,GAAG,MAAM,IAAI;AAEjD,QAAI,MAAM,QAAQ,WAAW,cAAc,KAAK;AAChD,WAAO,GAAG,EAAE,GAAG,MAAM,IAAI;AAEzB,YAAQ,aAAa,OAAO,MAAM;AAElC,UAAM,QAAQ,WAAW,cAAc,KAAK;AAC5C,WAAO,GAAG,EAAE,GAAG,IAAI,MAAM,MAAS;AAAA,EACtC,CAAC;AAED,KAAG,wBAAwB,YAAY;AACnC,UAAM,KAAK,MAAM,QAAiB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,SAUjC;AAED,UAAM,eAAe,EAAE;AAEvB,WAAO,OAAO,GAAG,UAAU,EAAE,GAAG,IAAI,MAAM,WAAW;AAAA,EACzD,CAAC;AACL,CAAC;",
6
6
  "names": []
7
7
  }